Skip to content

Instantly share code, notes, and snippets.

@codecademydev
Created July 10, 2020 06:39
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save codecademydev/f9521e27ee5abdf8bc3091395e1cde6d to your computer and use it in GitHub Desktop.
Save codecademydev/f9521e27ee5abdf8bc3091395e1cde6d to your computer and use it in GitHub Desktop.
Codecademy export
//Just a intresting game
#include<iostream>
#include<stdlib.h>
int main(){
srand (time(NULL));
int computer = rand() % 3+1;
int user = 0;
std::cout << "====================\n";
std::cout << "rock paper scissors!\n";
std::cout << "====================\n";
std::cout << "1) ✊\n";
std::cout << "2) ✋\n";
std::cout << "3) ✌️\n";
std::cout << "shoot! ";
std::cin>>user;
if(computer==user)
{
std::cout<<"Whoa! It is a tie";
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment