what is the difference between input and raw input statement
Answers
Answer:
Raw Input :-
Raw input is a form of input that takes the argument in the form of a string whereas the input function takes the value depending upon your input .
Say, a=input(5) returns a as an integer with value 5 whereas a=raw_input(5) returns a as a string of "5" .
Input Statement :-
An input statement or IO statement is a portion of a program that instructs a computer how to read and process information.
It pertains to gather information from an input device, or sending information to an output device .
→ Basically, the difference between raw_input and input is that the return type of raw_input is always string, while the return type of input need not be string only.
→ Python will judge as to what data type will it fit the best. In case you have entered a number, it will take it as an integer.
The BadSoorat here ✌
Answer:
The difference between raw_input and input is that the return type of raw_input is always string, while the return type of input need not be string only.