#program to enter string using input(function username=input("enter your name"print("hello ",usernamein [ ]runfileenter your nameindia hello india explanationin the above programthe user is prompted to enter the name which is stored in variable "usernameand hence when the username is printedthe name is printed the above program illustrates the use of input function to input string howeverif the user want to enter numeric datathere is need to use other functions along with input(function python accepts numeric input from the user in the form of an integer or float number using the int(and float(function respectively this is demonstrated in the following example#program to show use of int(and float(functions amountint(input("enter the amount")print("the amount is:",amountprofit=float(input("enter the profit")print("the profit is:",profitin [ ]runfileenter the amount the amount is enter the profit the profit is in [ ]runfileenter the amount the amount is enter the profit the profit is explanationafter displaying the string "enter the amount"the programs execution stops and wait for the user to type some text and then press enter key the string produced by the input function is passed to the int(function which produces value to assign to the variable "amountthe command amountint(input("enter the amount:")hence prompts the user to enter an integer value and stores it in the identifier amount the print command prints the value of amount the command profit=float(input("enter the profit")prompts the user to enter decimal value for the profit and stores it in the identifier profit the print command prints the value of profit in [ ]displays the results when the program was executed for the first time and in [ ]displays the results when the program was executed for the second time