does anyone know what' s wrong
here are the errors:
Quote:
Compiler: Default compiler
Executing g++.exe...
g++.exe "C:\Code\sh.cpp" -o "C:\Code\sh.exe" -pg -g3 -I"C:\DEV-CPP\include\c++" -I"C:\DEV-CPP\include\c++\mingw32" -I"C:\DEV-CPP\include\c++\backward" -I"C:\DEV-CPP\include" -L"C:\DEV-CPP\lib"
C:/Code/sh.cpp:42:20: warning: unknown escape sequence '\8'
C:/Code/sh.cpp:43:20: warning: unknown escape sequence '\9'
C:/Code/sh.cpp:87:34: warning: multi-line string literals are deprecated
C:/Code/sh.cpp: In function `void call(char)':
C:/Code/sh.cpp:87: parse error before `dlss'
C:/Code/sh.cpp:95:30: warning: multi-character character constant
C:/Code/sh.cpp:95: warning: overflow in implicit constant conversion
C:/Code/sh.cpp:98:30: warning: multi-character character constant
C:/Code/sh.cpp:98: warning: overflow in implicit constant conversion
C:/Code/sh.cpp:98: duplicate case value
C:/Code/sh.cpp:68: previously used here
C:/Code/sh.cpp:101:30: warning: multi-character character constant
C:/Code/sh.cpp:101: warning: overflow in implicit constant conversion
C:/Code/sh.cpp:101: duplicate case value
C:/Code/sh.cpp:71: previously used here
C:/Code/sh.cpp:103:30: warning: multi-character character constant
C:/Code/sh.cpp:103: warning: overflow in implicit constant conversion
C:/Code/sh.cpp:103: duplicate case value
C:/Code/sh.cpp:74: previously used here
C:/Code/sh.cpp:106:30: warning: multi-character character constant
C:/Code/sh.cpp:106: warning: overflow in implicit constant conversion
C:/Code/sh.cpp:106: duplicate case value
C:/Code/sh.cpp:77: previously used here
C:/Code/sh.cpp:109:30: warning: multi-character character constant
C:/Code/sh.cpp:109: warning: overflow in implicit constant conversion
C:/Code/sh.cpp:109: duplicate case value
C:/Code/sh.cpp:80: previously used here
C:/Code/sh.cpp:112:30: warning: multi-character character constant
C:/Code/sh.cpp:112: warning: overflow in implicit constant conversion
C:/Code/sh.cpp:112: duplicate case value
C:/Code/sh.cpp:83: previously used here
C:/Code/sh.cpp:115:30: warning: multi-character character constant
C:/Code/sh.cpp:115: warning: overflow in implicit constant conversion
C:/Code/sh.cpp:115: duplicate case value
C:/Code/sh.cpp:86: previously used here
Execution terminated
|
here is the code:
Code:
/*
Filename: tw.cpp
Progname: Telnet Wargames
By: Brian Gonzalez
Date: December 16, 2003
Purpose: Links to good telnet wargames
and telnet shell accounts
that might be of interest to
the novice and expert computer
buff alike.
*/
#include <iostream> // for i/o: cout, cin, endl,cin.get(), etc.
#include <cstdlib> // system() function for telnet site calls
using std::cin; // using cin for input
using std::cout; // using cout for output
using std::endl; // using endl to endlines of output
void call(char option); // calls() function prototype
int main(int argc, char** argv)
{
char option;
cout<< "Links to good telnet wargames\n"
<< "and telnet shell accounts\n"
<< "that might be of interest to\n"
<< "the novice and expert computer\n"
<< "buff alike\n" << endl;
cout<< endl << endl << endl // visual interface
<< "\t - Telnet - Servers -\n"
<< "\t-------------------------\n"
<< "\t1. sdf.lonestar.org\n"
<< "\t2. cyberspace.org\n"
<< "\t3. m-net.arbornet.org\n"
<< "t\4. nyx.net\n"
<< "t\5. vmsbox.cjb.net\n"
<< "t\6. h1me.yi.org\n"
<< "t\7. publiclinux.net\n"
<< "t\8. dlss.dhs.org\n"
<< "t\9. shellyeah.org\n"
<< "t\10. ductape.net\n"
<< "t\11. rootshell.be\n"
<< "t\12. hannover-internet.de\n"
<< "t\13. xbolt.net\n"
<< "t\14. nether.net\n"
<< "t\15. hobbiton.org\n"
<< "t\16. freeport.xenos.net\n"
<< "t\17. unix-shells.com\n"
<< "\tQ...Quit" << endl;
do
{
cout<< "\a\n\tEnter choice_ "; // option input and decision call() function
cin>> option;
call(option);
}
while (option != 0);
return 0;
}
void call(char option) // decision switch/case function (system calls for telnet)
{
switch (option) {
case '1' :
system("telnet sdf.lonestar.org");
break;
case '2' :
system("telnet cyberspace.org");
break;
case '3' :
system("telnet m-net.arbornet.org");
break;
case '4' :
system("telnet nyx.net");
break;
case '5' :
system("telnet vmsbox.cjb.net");
break;
case '6' :
system("telnet h1me.yi.org");
break;
case '7' :
system("telnet publiclinux.net");
break;
case '8' :
system("telnet dlss.dhs.org");
break;
case '9' :
system("telnet shellyeah.org");
break;
case '10' :
system("telnet ductape.net");
break;
case '11' :
system("telnet rootshell.be");
break;
case '12' :
system("telnet hannover-internet.de");
case '13' :
system("telnet xbolt.net");
break;
case '14' :
system("telnet nether.net");
break;
case '15' :
system("telnet hobbiton.org");
break;
case '16' :
system("freeport.xenos.net");
break;
case '17' :
system("unix-shells.com");
break;
case 'q' :
case 'Q' :
exit(0);
default:
cout<< '\t' << "ERROR_CODE 187_1337, Invalid Input" << '\a' << endl;
}
}