![]() |
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| High Level Programming Post questions about C, C++, Java, SQL, and other programming languages here. |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| main function | arun.viswanath | High Level Programming | 6 | 03-07-2008 12:43 PM |
| Return value (int) from main to calling shell | flounder | High Level Programming | 3 | 09-25-2006 11:14 PM |
| Calling a function | ashika | UNIX for Dummies Questions & Answers | 5 | 09-12-2006 08:58 PM |
| Calling subscript but sleep halts the main script | doublejz | Shell Programming and Scripting | 1 | 09-12-2005 03:08 PM |
| calling a c function from shell | seshagiri | UNIX for Dummies Questions & Answers | 4 | 12-06-2000 09:51 PM |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
||||
|
c++ calling main() function
i just finished a project for a c++ class that i wrote at home on my computer, compiled with gcc. when i brought the code into school it would not compile, it would complain that cannot call main() function. at school we use ancient borland c++ from 1995. anyway my program has 20 different functions, and each one hasa menu to start the program over, some with switch structure, and others with else if, everyone calls the main function when it is started over, so my question is, which is right? in c++ should you be able to call the main function from other functions? or is this a lax in conformity with gcc?
--- i simply created a new function identical to main() and called that when i need to start over. |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|