Categories:
Android (1)
Audio (7)
C/C++ (2)
Compression (7)
Database (6)
Document (14)
Email (3)
General (50)
Graphics (17)
Image (8)
Java (1)
Picture (1)
Presentation (7)
Programming (17)
Spreadsheet (11)
Video (8)
Web (13)
Windows (63)
XML (4)
Other Resources:
.CPP - File Extension for C++ Source Files
What is CPP? CPP, short name for C++, is used as the file extension for C++ Source files. .CPP files are text files that can be opened by Notepad or any text editors. See the sample .CPP file included below.
✍: FYIcenter.com
File Extension: .CPP
MIME Type: text/plain
File Content: C++ Source
.CPP files are C++ Source files, which contain C++ programming source codes. Here is a sample .CPP C++ Source file, mapInsert.cpp, containing some simple C++ statements:
#include <map>
#include <iostream>
using namespace std;
class Data {
public:
Data(int val = 0) { mVal = val; }
int getVal() const { return mVal; }
void setVal(int val) {mVal = val; }
protected:
int mVal;
};
int main(int argc, char** argv) {
map<int, Data> dataMap;
pair<map<int, Data>::iterator, bool> ret;
ret = dataMap.insert(make_pair(1, Data(4)));
if (ret.second) {
cout << "Insert succeeded!\n";
} else {
cout << "Insert failed!\n";
}
ret = dataMap.insert(make_pair(1, Data(6)));
if (ret.second) {
cout << "Insert succeeded!\n";
} else {
cout << "Insert failed!\n";
}
return (0);
}
.CPP C++ Source file sample: Click sample.cpp to download.
Since .CPP text files are in text format, you can use Notepad or any text editor to create or modify them. No special software is needed.
For for information on how to use .CPP C++ Source files, see links below:
2012-07-08, 7620👍, 0💬
Popular Posts:
What is PRN? PRN, short name for Printable, is used as the file extension for files padded with spac...
What is MDB? MDB, short name for Microsoft Database, is used as the file extension for Microsoft Acc...
What is CRT or CER? CRT or CER, short name for Certificate, is used as the file extension for PKI (P...
File extension CLASS is used for Java compiled class files. A CLASS sample file is provided. Free JV...
What is XLSB? XLSB, short name for Excel Spreadsheet Binary, is used as the file extension for sprea...