IITDU Forum
Would you like to react to this message? Create an account in a few clicks or log in to continue.

find mistake

2 posters

Go down

find mistake Empty find mistake

Post by BIT0112-Rokon Mon Apr 05, 2010 11:09 am

Code:
#include <conio.h>
using namespace std;

void OS_Solaris_print()
{
cout<<"Solaris - Sun Microsystems\n";
}

void OS_Windows_print()
{
cout<<"Windows - Microsoft\n";

}
void OS_HP-UX_print()
{
cout<<"HP-UX - Hewlett Packard\n";
}

int main()
{
int num;
cout<<"Enter the number (1-3):\n";
cin>>num;
switch(num)
{
case 1:
OS_Solaris_print();
break;
case 2:
OS_Windows_print();
break;
case 3:
OS_HP-UX_print();
break;
default:
printf("Hmm! only 1-3 :-)\n");
break;
}
getch();
return 0;
}


There is a silly mistake.. can you find it..?
BIT0112-Rokon
BIT0112-Rokon
Programmer
Programmer

Course(s) :
  • BIT

Blood Group : O+
Posts : 673
Points : 1269

http://blog.codexplo.org

Back to top Go down

find mistake Empty Re: find mistake

Post by BIT0122-Amit Mon Apr 19, 2010 12:44 am

answer sent to private message. check it out Smile
BIT0122-Amit
BIT0122-Amit
Founder
Founder

Course(s) :
  • BIT

Blood Group : O+
Posts : 4187
Points : 6605

https://iitdu.forumotion.com

Back to top Go down

Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum