Skip to content

Instantly share code, notes, and snippets.

@AreRex14
Created February 17, 2021 15:15
Show Gist options
  • Save AreRex14/a94ac4c0ebf3abcca7604c7b988dfb28 to your computer and use it in GitHub Desktop.
Save AreRex14/a94ac4c0ebf3abcca7604c7b988dfb28 to your computer and use it in GitHub Desktop.
A program that will tell you the year where you will be 100 years old
import datetime
print('This program will tell you the year where you will be 100 years old.')
name = input("Enter your name: ")
age = int(input("Enter your age: "))
now = datetime.datetime.now()
year = str((now.year - age) + 100)
rand_num = int(input("Please enter any number: "))
print(str(rand_num * name), "\n", "will be 100 years old in {}".format(year))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment