input(): ======== ==> a built-in function. ==> input() can use to take value for the variable during the execution of the program. a = 10 ==> compile time definition can able to run the program with fixed value Syntax: identifier = input("text") function: ======== a named block can be defined with "def" keyword to specify the action with group of statements. ex: def Addition(): a = 10 b = 20 c = a+b print(c) a = 10 b = input("Enter a value:") print(a,b) print(a,b) print(a,b) ============== Note: ==== input() can able to take the value in string format only by default. String ==> group of characters which we can enclose with single quotes or double quotes. Ex: 'p', 'python' "p", "Python" a = input("Enter a value for a:") b = input("Enter a value for b:") print(type(a)) print(type(b)) ===================================================== Type Conversion: =============== ==> also called as "type casting" ==> can use to convert the data from one form to another form. int ==> float float ==> int ==> for type conversion: the pre-defined functions are: 1) int() 2) float() 3) complex() 4) bool() int(): ===== ==> can be used to convert any data into an integer. Syntax: int(any data) # binary ==> decimal # octal ==> decimal # hexadecimal ==> decimal a = 0b11001 b = 0o123 c = 0X1a2f print(int(a),int(b),int(c)) # decimal format # float ==> integer d = 1.2233 e = 123.123 print(int(d)) print(int(e)) # complex ==> integer (not possible) # f = 12-23j # # print(int(f)) # boolean ==> integer f = True g = False print(int(f)) print(int(g))