When I try to open a new file to type C++ code, I find that I need to choose one of a few folders which contain other folders such as "Source Files". Can I just type, compile and run C++ code with just a new text file?
Printable View
When I try to open a new file to type C++ code, I find that I need to choose one of a few folders which contain other folders such as "Source Files". Can I just type, compile and run C++ code with just a new text file?
which compiler/OS are you using?
im not sure but i think ur tryin to say that u cant edit or create a program in the compiler (is that right?) u c most compilers need a source file that was created using notepad and saving it as a .cpp file. although u cant create u should be able to edit. if you cant, i suggest u get a new compiler. i reccomend dev c++, completely free. heres a link to it
http://optusnet.dl.sourceforge.net/s...p4990setup.exe
hope u enjoy!
Yes. C++ source code is plain ASCII text. It's NOT a special format. (Don't use MS Word format, RTF, HTML, etc.)Quote:
Can I just type, compile and run C++ code with just a new text file?
Some compilers (IDE's) will have an "open new project" option. Using this, rather than "open new text file" will help configure the compiler and linker.
Your compiler may expect your source file to have a .cpp, or a .c extension, and it will expect to find the source file in a particular folder.