#include
#include
#include
#include
#include
main()
{
int score=0; char ch,temp,login[100],*pass; textcolor(0); textbackground(15); clrscr(); printf("\n\n\n\n\n\n\n\n\n\n\t\tWELCOME TO 'YUUVVA'ONLINE EXAMINATION\n\n\t\tPRESS ENTER TO CONTINUE\n\n\t\t"); temp=getchar(); clrscr(); printf("\n\n\n\n\n\n\n\n\n\t\t\tENTER YOUR LOGIN\n\n\t\t\t"); scanf("%s",login); printf("\n\n\n\n\t\t\tENTER PASSWORD\n\n\t\t\t"); pass=getpass(" "); while(strcmp(login,pass)!=0) { printf("\n\n\t\t\tINVALID PASSWORD\n\n\t\t\t"); printf("\n\n\t\t\tENTER YOUR PASSWORD\n\n\t\t\t"); pass=getpass(" "); } temp=getchar(); clrscr();
printf("\n\n\t\tREAD THE FOLLOWING RULES CAREFULLY\n\n\n1.THE EXAMINATION IS FOR 3 SUBJECTS: PHYSICS, CHEMISTRY, MATHEMATICS\n\n2.EACH SUBJECT HAS 10 QUESTIONS EACH\n\n3.THE QUESTIONS ARE OF MULTIPLE CHOICE TYPE WITH 4 OPTIONS A, B, C, D OUT OF WHICH ONLY ONE IS APPROPRIATE\n\n4.+4 MARKS FOR EVERY CORRECT ANSWER AND A PENALTY OF -1 MARKS WILL BE AWARDED FOR EACH WRONG ANSWER\n\n5.YOU ARE ALLOWED TO QUIT ANYTIME IN BETWEEN BY PRESSING 'Q' ON THE KEYBOARD WHEREIN YOUR FINAL SCORE OUT OF 120 WILL BE DISPLAYED\n\n\n\n\n\n\n\n\t\t\tALL THE BEST!!!\n\n");
temp=getchar(); clrscr(); printf("\n\n\n\n\n\n\n\n\t\t\t\t\tPHYSICS\n"); temp=getchar(); if(!kbhit()) clrscr(); printf("\n\n\n\n1.An electric dipole is placed at an angle of 30 deg to a non uniform electric field. The dipole will experience \n\nA. a torque as well as a translational force \n\nB. torque only \n\nC. translational force only in the direction of the field \n\nD. translational force only in the direction normal to the direction of field\n\n"); scanf("%c",&ch); ch=toupper(ch);
temp=getchar(); if(ch=='Q') { clrscr(); printf("\t\tYOUR FINAL SCORE\n\n\n\t\t%d",score); exit(1); }
else { if(ch=='A') score+=4; else score-=1; } clrscr(); printf("\n\n\n\n2.A particle located