cool programming projects in python code example
Example: python projects with source code for beginners
##-Guess The Number. Write a programme
## where the computer randomly generates
##a number between 0 and 20
from random import randint
print("Hey there! In this game, you will have to guess a random number from 1, 20. Good luck!")
user_name = input("What's your name?\n")
print(user_name,"pick a number!")
guess = input()
random_int = randint(0, 20)
if guess != random_int:
print('That was wrong!', random_int, "was the number!")
else:
print('That was correct!')