/*
Regrads,
Muhammad Hamza Baig
Biggnerstart.blogspot.com
*/
#include <iostream>
using namespace std;
void computeUserLevel (char *) ;
int main()
{
cout<<"\t\tProgram To Predict User Programming Level"<<endl;
char Y [4];
for (int k=0; k<=0; k++)
{
cout<<"Q: Switch is a loop?\nA: ";
cin>> Y[0];
cout<<"Q: Pointers store memory addresses?\nA: ";
cin>> Y[1];
cout<<"Q: Semicolon after for loop is an error?\nA: ";
cin>>Y[2];
}
computeUserLevel(Y);
return 0;
}
void computeUserLevel (char *ptr)
{
if (*ptr == 'f' && *(ptr+1) == 't' && *(ptr+2) == 'f')
{
cout<<"Your level is advanced";
}
else if (*ptr == 'f' && *(ptr+1) == 't' && *(ptr+2) == 't')
{
cout<<"Your level is Intermediate";
}
else
cout<< "Your level is Beginner"<<endl;
system ("PAUSE");
}
Regrads,
Muhammad Hamza Baig
Biggnerstart.blogspot.com
*/
#include <iostream>
using namespace std;
void computeUserLevel (char *) ;
int main()
{
cout<<"\t\tProgram To Predict User Programming Level"<<endl;
char Y [4];
for (int k=0; k<=0; k++)
{
cout<<"Q: Switch is a loop?\nA: ";
cin>> Y[0];
cout<<"Q: Pointers store memory addresses?\nA: ";
cin>> Y[1];
cout<<"Q: Semicolon after for loop is an error?\nA: ";
cin>>Y[2];
}
computeUserLevel(Y);
return 0;
}
void computeUserLevel (char *ptr)
{
if (*ptr == 'f' && *(ptr+1) == 't' && *(ptr+2) == 'f')
{
cout<<"Your level is advanced";
}
else if (*ptr == 'f' && *(ptr+1) == 't' && *(ptr+2) == 't')
{
cout<<"Your level is Intermediate";
}
else
cout<< "Your level is Beginner"<<endl;
system ("PAUSE");
}
First run this program by yourself and then post it.Its give a big error like error of the father.try it
ReplyDeleteFirst run this program by yourself and then post it.It give an error like error of the father.try it.
ReplyDeleteFirst run this program by yourself and then post it.It gives an error like error of the father.try it.
ReplyDeleteFirst run this program by yourself and then post it.It gives an error like error of the father.try it.
ReplyDeleteMr. Zeeshan i respect for your opinion but please execute by yourself properly than make a comment here for further detail.
ReplyDeleteif you didn't get code understanding why would you not clarify your concepts or ask about what the problem everyone is executing this code than ping me for further detail.
ReplyDelete