Simple Game C++ this is a simple game making c++ use functions and if/else statement and simple cout and cin. the game make is veary easy anyone can make the game. this is my blpg and my youtube channel you can subscribe the channel and help me to faster grow my channel. i hope you all help me code #include <iostream> using namespace std; void start_game(){ char answer; int score = 1; cout<< "What is 1+1" <<endl; cout<< "(a)= 5" <<endl; cout<< "(b)= 6" <<endl; cout<< "(c)= 9" <<endl; cout<< "(d)= 2" <<endl; cout<< "choes a option " <<endl; cin>>answer; if (answer == 'd' ){ cout<< "you choes right answer" <<endl; cout<< "score::" <<score++<<endl; } else { cout<< "You choes wrong Answer" <<endl; } cout<< "Wha...
Source code #include <iostream> #include <conio.h> using namespace std; int main() { //find the area of rectangle int l,b; cout<< "Enter the value of 'l'-" ; cin>>l; cout<< "Enter the value of 'b'-" ; cin>>b; cout<< "The area of rectangle is=>" <<l*b; getch(); cout<< "\nmake by:- " <<endl; cout<< "S K E L T O N " <<endl; cout<< "P R O G R A M M E R " <<endl; return 0; }
Comments
Post a Comment