- Messages
- 92
- Reaction score
- 0
- Points
- 26
#include<iostream>
#include<string>
using namespace std;
int main()
{
string x,y;
do
{
system ("cls")
cout<<"SYSTEM MENU\n"
<<"a. Activity 1\n"
<<"b. Activity 2\n"
<<"c. Activity 3\n"
<<"d. Activity 4\n"
<<"e. Activity 5\n"
<<"f. Activity 6\n"
<<"g. Activity 7\n";
cout<<"Enter your choice: ";
cin>>x;
if (x=="a")
{
system ("cls")
cout<<"My First C++ program.\n";
cout<<"\n\nDo you want to quit? (y/n)";
cin>>y;
}
else if (x=="b")
{
system ("cls")
cout<<"Name\t\t\t\t\t\t\t\t\t\t"<<"Name";
cout<<"\t\t\t\t\t"<<"Name\t\t\t\t\t";
cout<<"Name\t\t\t\t\t\t\t\t\t\t"<<"Name";
cout<<"\n\nDo you want to quit? (y/n)";
cin>>y;
}
else if (x=="c")
{
system ("cls")
int a,b,z;
cout<<"Enter first number: ";
cin>>a;
cout<<"Enter second number: ";
cin>>b;
z=a+b;
<<"The sum of the two numbers is "
<<sum
cout<<sum<<"\n\n\n";
cout<<"\n\nDo you want to quit? (y/n)";
cin>>y;
}
else if (x=="d")
{
system ("cls")
char a[99],b[99],c[99],d[99],e[99],f[99];
cout<<"Name: ";
cin.getline (a,99);
cout<<"Address: ";
cin.getline (b,99);
cout<<"Age: ";
cin.getline (c,99);
cout<<"Gender: ";
cin.getline (d,99)
cout<<"Course: ";
cin.getline (e,99);
cout<<"Section: ";
cin.getline (f,99);
cout<<"Hello "<<a<<" ! You are "<<c<<" years of age and you leave at "<<b<<". Goodluck to your "<<e<<" course.
cout<<"\n\nDo you want to quit? (y/n)";
cin>>y;
}
}
while (y=="n");
return 0;
}
Pa help ang hirap . Di ko alam saan dyan un error eh .Pa help !!
#include<string>
using namespace std;
int main()
{
string x,y;
do
{
system ("cls")
cout<<"SYSTEM MENU\n"
<<"a. Activity 1\n"
<<"b. Activity 2\n"
<<"c. Activity 3\n"
<<"d. Activity 4\n"
<<"e. Activity 5\n"
<<"f. Activity 6\n"
<<"g. Activity 7\n";
cout<<"Enter your choice: ";
cin>>x;
if (x=="a")
{
system ("cls")
cout<<"My First C++ program.\n";
cout<<"\n\nDo you want to quit? (y/n)";
cin>>y;
}
else if (x=="b")
{
system ("cls")
cout<<"Name\t\t\t\t\t\t\t\t\t\t"<<"Name";
cout<<"\t\t\t\t\t"<<"Name\t\t\t\t\t";
cout<<"Name\t\t\t\t\t\t\t\t\t\t"<<"Name";
cout<<"\n\nDo you want to quit? (y/n)";
cin>>y;
}
else if (x=="c")
{
system ("cls")
int a,b,z;
cout<<"Enter first number: ";
cin>>a;
cout<<"Enter second number: ";
cin>>b;
z=a+b;
<<"The sum of the two numbers is "
<<sum
cout<<sum<<"\n\n\n";
cout<<"\n\nDo you want to quit? (y/n)";
cin>>y;
}
else if (x=="d")
{
system ("cls")
char a[99],b[99],c[99],d[99],e[99],f[99];
cout<<"Name: ";
cin.getline (a,99);
cout<<"Address: ";
cin.getline (b,99);
cout<<"Age: ";
cin.getline (c,99);
cout<<"Gender: ";
cin.getline (d,99)
cout<<"Course: ";
cin.getline (e,99);
cout<<"Section: ";
cin.getline (f,99);
cout<<"Hello "<<a<<" ! You are "<<c<<" years of age and you leave at "<<b<<". Goodluck to your "<<e<<" course.
cout<<"\n\nDo you want to quit? (y/n)";
cin>>y;
}
}
while (y=="n");
return 0;
}
Pa help ang hirap . Di ko alam saan dyan un error eh .Pa help !!