Dev-C++ Fenster blinkt nur kurz auf???
-
getch() gehört zu conio.h. Diese Biliothek ist nicht Standard. Daher ist die Methode mit einer eigenen protablen wait-Funktion besser geeignet.
-
#include <iostream.h>
#include <conio.h>
void main()
{
cout<<"Hello, world!"<<endl;
getch();
}also wenn ich ds eingebe kommt nur ne fehlermeldung mit die Qwelldatei ist nicht kompiliert...
-
cxpo schrieb:
also wenn ich ds eingebe kommt nur ne fehlermeldung mit die Qwelldatei ist nicht kompiliert...
Wundert mich auch nicht, der Code ist falsch. Lies dir Seite 1 nochmal durch, und du wirst fündig.
-
#include <iostream> using namespace std; int main() { cout << "Hello, world!" << endl; cin.get(); return 0; }
ahh sry... also damit klappt es...
danke nochmals
-
Seht doch in dei Konsolen-FAQ. SideWinder hat dort einen Support Beitrag verfasst.
MFG CSS
-
#include <iostream> const char NL = '\n'; void wait() { std::cin.clear(); std::streambuf * pbuf = std::cin.rdbuf(); std::streamsize size = pbuf->in_avail(); std::cin.ignore(size); std::cin.get(); } int main() { std::cout << "Hello, world!" << NL; wait(); }