spidEY v2.0
16-12-2008, 14:51
#include <iostream>
#include <cstdlib>
#include <conio.h>
#include <string>
#include <stdio.h>
#include <windows.h>
using namespace std;
int main(){
string input;
string cmd1;
cmd1 ="exit";
system("title DOS");
begin:
printf ("Input: ");
cin>>input;
if (input == cmd1) {
return 0;
}
else {
cout<<endl;
printf("UNKNOWH COMMDAND");
getch();
system("cls");
goto begin;
}
}
Ovo sam zasada napravio iz dosade, što mislite, jel mogu napraviti nešto s ovom osnovom? :)
#include <cstdlib>
#include <conio.h>
#include <string>
#include <stdio.h>
#include <windows.h>
using namespace std;
int main(){
string input;
string cmd1;
cmd1 ="exit";
system("title DOS");
begin:
printf ("Input: ");
cin>>input;
if (input == cmd1) {
return 0;
}
else {
cout<<endl;
printf("UNKNOWH COMMDAND");
getch();
system("cls");
goto begin;
}
}
Ovo sam zasada napravio iz dosade, što mislite, jel mogu napraviti nešto s ovom osnovom? :)