| | |
miracle c problem
Please support our C advertiser: Programming Forums - DaniWeb Sister Site
![]() |
•
•
Join Date: Feb 2008
Posts: 14
Reputation:
Solved Threads: 0
I've never coded in c before but have to for a class that I'm taking. I'm using miracle c as my compiler but am having a strange error when I try to execute a program. The program executes, but the command window instantly closes so I can't even tell if the program is working as it should. This seems like it should be a fairly simple problem to solve, but is really annoying!
thanks,
nick clark
thanks,
nick clark
It's not an error. Windows automatically closes console applications once they're finished. To pause the program before it quits (so you can view the console output), put
getchar(); at the end of your program. "Technological progress is like an axe in the hands of a pathological criminal."
All my posts may be freely redistributed under the terms of the MIT license.
All my posts may be freely redistributed under the terms of the MIT license.
write getchar(); before return. That should pause until you press enter if no characters was left behind in the stdin.
If you can change compiler. Miracle C is broken. Look here for some suggestions
If you can change compiler. Miracle C is broken. Look here for some suggestions
"If it moves, tax it. If it keeps moving, regulate it, and if it stops moving, subsidize it" - Ronald Reagan
u can also getch() but it doesnot work in some compiler.
Freedom in the Mind, Faith in the words.. Pride in our Souls...
Indian Developer
http://falaque.wordpress.com/
Indian Developer
http://falaque.wordpress.com/
Why do people insist on making bad suggestions, especially after a good suggestion has been made?
And if you read the Rules, they request you use the word you, not the letter u, so people that don't speak English well can understand your post.
And if you read the Rules, they request you use the word you, not the letter u, so people that don't speak English well can understand your post.
The 3 Laws of the Procrastination Society:
1) Never do today that which can be put off until tomorrow
2) Tomorrow never comes
1) Never do today that which can be put off until tomorrow
2) Tomorrow never comes
Freedom in the Mind, Faith in the words.. Pride in our Souls...
Indian Developer
http://falaque.wordpress.com/
Indian Developer
http://falaque.wordpress.com/
![]() |
Similar Threads
- Hotmail Login Problem! (Web Browsers)
- Big problem with a Compaq Presario 5410US (Troubleshooting Dead Machines)
- The Biggest Mathematical Miracle in the World (Geeks' Lounge)
- bouncing around..when typing (Windows NT / 2000 / XP)
- Desperate and eagar to learn!!! (C++)
- Can't get more than 16 color after 98 reinstall (Windows 95 / 98 / Me)
Other Threads in the C Forum
- Previous Thread: character input through command line problem
- Next Thread: Get the Makefile.am from the Makefile
Views: 1799 | Replies: 5
| Thread Tools | Search this Thread |
Tag cloud for C
adobe ansi api array arrays asterisks binarysearch calculate centimeter char convert copyimagefile copypdffile cprogramme createcopyoffile csyntax directory drawing dynamic executable fflush file fork frequency getlasterror givemetehcodez graphics gtkgcurlcompiling hacking hardware highest homework i/o inches incrementoperators infiniteloop initialization interest km lazy linked linkedlist linux linuxsegmentationfault list locate logical_drives match matrix microsoft motherboard multi mysql number open opendocumentformat opensource owf pattern pdf performance pointer pointers posix power problem probleminc program programming pyramidusingturboccodes read recursion recv repetition scanf scheduling scripting segmentationfault send shape socketprograming spoonfeeding stack standard string strings structures student systemcall test testautomation unix user variable visualstudio voidmain() wab win32 win32api windows.h






