Home  >  Article  >  Backend Development  >  How to delete input errors in python

How to delete input errors in python

藏色散人
藏色散人Original
2019-10-11 14:34:2710502browse

How to delete input errors in python

How to delete input errors in python?

Python's commonly used input function raw_input(), if you make a mistake during the input process, you cannot backspace to cancel the entered characters like you can on the command line, and you have to re-enter.

How can I cancel the input character backspace similar to the command line?

This problem is caused by different operating systems:

● Under the Windows operating system, if you make a mistake during the input process of raw_input(), you can use backspace to cancel the input. Characters;

● In some Unix-like systems, delete is used instead of backspace;

● Under Ubuntu, delete is not possible, but ctrl backspace is.

Recommended: "Python Tutorial"

The above is the detailed content of How to delete input errors in python. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn