Thursday, September 5, 2019

#include<stdio.h>
#include<conio.h>
int main()
{
int a,b,c,d,e;
char m,n,name[20];
clrscr();
printf("    ****************** WELCOME IN MIND READER GAME *******************\n\n");
printf("   ........................Now I Will Control Your Mind......................\n\n");
printf("____________ You read all the line Carefully in this Program_______________\n\n");
printf("****************************** START ******************************\n\n\n");
printf("\nPlease Enter Your name :  ");
gets(name);
printf("\n\n\n        For Start this game You enter any one digit number : ");
scanf("%d",&a);
if(a>=0&&a<=9)
 {
 printf("\n\n\n ___________________ NOW YOU THINK A NUMBER IN YOUR MIND _________________\n\n");
 }
else
{
printf("\n\n You are not Enter any One digit No .. Ok no Problem !!");

printf("\n\n__________________NOW YOU THINK A NUMBER IN YOUR MIND ____________________\n\n");
}


printf("\n\n Now Enter any One digit No to continue the Game :   ");
scanf("%d",&b);
if(b>=0&&b<=9)
{
printf("\n\n\n_________________NOW YOU COUNT YOUR NUMBER TWO TIMES MEANS ( your no which you think in your mind * 2 )\n\n");
}
else
  {
  printf(" \n\n You are not enter any one digit number \n\n");
  printf("\n _________NOW YOU COUNT YOUR NUMBER TWO TIMES MEANS ( your no * 2)____________\n\n");

  }


  printf("\n\n Enter any one digit number to Continue the Game ");
  scanf("%d",&c);
if(c>=0&&c<=9)
 {
  d=a+b+c;
   if(d%2==0)
     {
      if(d<=10&&d>0)
   e=d;
      else if(d==0)
 e=6;
      else if(d>10&&d<=20)
 e=d-8;
      else
 e=d-16;
      }
   else
   {
   if(d>0&&d<=10)
     e=d+1;
   else if(d>10&&d<20)
    e=d+1;
   else
     e=d-7;
  }
  }
  else
    {
    printf("\n\n You are not Enter any One digit no\n\n");
    e=10;
    }


 printf("\n\n\n______________________NOW ADD %d WITH YOUR NEW VALUE____________________\n\n",e);
 fflush(stdin);
 printf("\n\n TO Continue this game Please press Y :   ");
 scanf("%c",&m);
 if(m=='y'||m=='Y')
  {
  printf("\n\n\n ________________ NOW YOU DEVIDE 2 WITH YOUR PREVIOUS VALUE_______________\n\n");
  }
 else
 {
 printf(" \n\nYou are not Enter Y.....But no Problem\n ");
 printf("_______________________NOW YOU DEVIDE 2 WITH YOUR PREVIOUS VALUE________________\n\n");
 }
 printf("\n\n\n______________Now Your Value is to Subtracted by the first number which you thought first time____________\n\n");
 printf("\n\n\n          Now I told You the answer \n\n   ");
 fflush(stdin);
 printf("\n\n                            Enter Y to know Your answer :  ");

 scanf("%c",&n);
 if(n=='y'&&n=='Y')
  {
  printf("\n\n\n @@@@@@@@@@@@@@@@@@@@@ NOW YOUR ANSWER IS %d @@@@@@@@@@@@@@@@@@@@@@",e/2);
  printf("\n\n                       Was it Right                      ");
  }
  else
  {
  printf("         You are not entered Y key ....... But no problem  \n\n");
  printf(" \n @@@@@@@@@@@@@@@@@@@ NOW YOUR ANSWER IS %d @@@@@@@@@@@@@@@@@@@@\n\n",e/2);
  }
  printf("                  I hope that You got the answer %s                   \n\n\n",name);

  printf("__________________________ THANK YOU %s__________________\n\n",name);
  getch();
  return 0;
  }

No comments:

ATM Program by Anupam Guin

#include<stdio.h> int main() { int cp,pin; int a,add,option,with; printf(" WELCOME IN THIS ATM ...