Well, sort of. You would have to alter some of the include file entries and recode most of the class calls. The very basics would be OK.
If you are going back and forth, this will drive you NUTS.
2006-09-13 01:02:04
·
answer #1
·
answered by Anonymous
·
1⤊
0⤋
You can't go backwards. C++ is an extension or superset of C, meaning that it has more key words and operators. Therefore, no, you can't compile a C++ program on a strictly C compiler. The one thing that you will have a possibility of doing is compiling a C program on a C++ compiler, and errors can creep in here depending on the code used. Fortunately, there are very few compilers left in the world that are incapable of doing both. That is to say, compatibility modules are shipped with most modern compilers or IDE's intended for C++. So, you can likely find a C++ compiler for free quit easily, maybe even the one you have now. Check your documentation, then if you need to get a free compiler try the URL below. They also have tutorials, articles, editors and compilers in other languages.
2006-09-13 05:50:25
·
answer #2
·
answered by Anonymous
·
0⤊
0⤋
C++ is an upgraded version of C. And yes you can compile a C++ program using C compiler, provided you used biult-in function in C++ that is in C. Functions such as 'print', 'scan'.
For more free C++/C source codes, visit, http://smartcoder.awardspace.com/
Then go to the C++/C category.
KaBalweg
http://smartcoder.awardspace.com/
2006-09-13 01:20:37
·
answer #3
·
answered by dabsani 3
·
0⤊
0⤋
Use header document like extremely of cstdio, in new compilers. may be attempt a goto fact that ought to make your compiler somewhat warm decrease than the collar. Sorry yet thats all i will think of of.
2016-11-07 05:43:55
·
answer #4
·
answered by ? 4
·
0⤊
0⤋
sometimes yes, c++ program can be compiled on c compiler.
for example if it has cin , cout, the answer will be no.
2006-09-13 01:32:25
·
answer #5
·
answered by iyiogrenci 6
·
0⤊
0⤋
no..
as far i as i know u can run ur c programs in c++, but
u cant run ur c++ programs in c.
2006-09-13 01:18:43
·
answer #6
·
answered by Hari 1
·
1⤊
0⤋
no
2006-09-13 01:01:37
·
answer #7
·
answered by Faheem 4
·
0⤊
0⤋