#user_input_a_number_1
import random
import sys
import os

##programs can read in whatever a user types on the keyboard.
##the program "prompts" the user for a response and then waits until the
##user presses the "enter" key.
##
##The program below prompts the user to enter a number  and then
##does something with that input.  You will need to know how to do this
##for an upcoming assignment

#prompt the user to enter something:
print("Enter a number (e.g. 25 ) and press the Enter key :", end="")

#get value from user
num_in_str = sys.stdin.readline()
#note:   The readline() function creates a string with a trailing "\n"
#  this has to be removed before the string can be converted to a number.


#to remove the trailing "\n",  use rstrip()
num_in_str = num_in_str.rstrip()


print("\nYou entered : ",num_in_str)
#num_in_str is a string, not a number.
#It has to be converted to a number before it will work
#as desired #in an arithmatic expression  like  4*num

#the two lines show an example of trying to use arithmatic
#on a string
new_num = 5*num_in_str
print("\nThe statement : 'new_mum = 5*num_in_str' will give : ",new_num)
print("That is not a correct calculation of 5 * ",num_in_str)
      
#the next two statements convert ths string to a number and
#then uses it in a calculation. 
num_in = int(num_in_str)
print  ("\nYou entered ", num_in, " and 5 times that number is ", (5*num_in))

