What is difference between raw_input and input in python?



What is difference between raw_input and input in python?..

Answer / Neerak Kumar Meena

In Python, raw_input() returns the user's input as a string by default, while input() accepts input from the user, converts it to a string if no data conversion is specified, and can convert the input to other types (like integer or float) using type casting functions.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Python Interview Questions

Are Tuples immutable?

1 Answers  


How to get all keys from dictionary ?

1 Answers  


What is raise keyword do in python exception handling?

1 Answers  


What is difference between yield and return?

1 Answers  


Which is better java or python?

1 Answers  


How to check whether a module is installed in python?

1 Answers  


Is python is a case sensitive?

1 Answers  


What applications use python?

1 Answers  


Please explain when is the python decorator used?

1 Answers  


How do you use super in python?

1 Answers  


Name some of the important modules that are available in python.

1 Answers  


How will you print the contents of a file?

1 Answers  


Categories