Jul-16-2018, 01:41 PM
I have created a simple game for my nephew. He wants to share the game with his friends.I have no clue on how to convert this into an exe file. Need assistance on how this simple game can be shared without requiring to have python installed on a computer.
#!/usr/bin/env python import random print("Lets play the Rock, Paper & Scissors Game") print("..........................................") choices=['rock','paper','scissors'] computer=random.choice(choices) pscore=0 cscore=0 for x in range(5): player = input('Please select Rock, Paper or Scissors\n') if computer=='rock': if player=='paper': print('you have won!') pscore=pscore+1 cscore=cscore+0 print('The Computer chose ',computer) elif player=='scissors': print('you have lost') pscore=pscore+0 cscore=cscore+1 print('The Computer chose ', computer) else: print('its a draw') print('The Computer chose ', computer) elif computer=='scissors': if player=='rock': print('you have won!') pscore=pscore+1 cscore=cscore+0 print('The Computer chose ', computer) elif player=='paper': print('you have lost') pscore=pscore+0 cscore=cscore+1 print('The Computer chose ', computer) else: print('its a draw') print('The Computer chose ', computer) else: if player=='scissors': print ('you have won!') pscore=pscore+1 cscore=cscore+0 print('The Computer chose ', computer) elif player=='rock': print('you have lost') pscore=pscore+0 cscore=cscore+1 print('The Computer chose ', computer) else: print('its a draw') print('The Computer chose ', computer) print('Computer Score',cscore) print('Player Score',pscore) if cscore > pscore: print('You Lost!!,') elif cscore < pscore: print('You win!') else: print('its a draw')