Calculations and New Job
March 09, 2018
Started a new job today. Wrapping up this week's work with Python revision, so here's a simple division calculator using (float(raw_input(">")))
to get user input. I also use \n
to create clean lines when terminal gives you the results.
def division(value_1, value_2):
print "\nDividing %d / %d\n" % (value_1, value_2)
return value_1 / value_2
value_1 = (float(raw_input(">")))
value_2 = (float(raw_input(">")))
result = division(value_1, value_2)
print "\nThe answer is %d.\n" % (result)
Recent Entries
- Jurassic World Rebirth July 02, 2025
- Vintage Adverts July 02, 2025
- Ready Player One June 29, 2025