I want to make a typing effect but I can't print a backspace. I tried using print('\b') but it just printed out an x-ed out square. Are there any other ways to print a backspace? If it helps I'm using Mu as my code editor.
Is there a way to print a backspace in Python without using \b?
555 Views Asked by GoudyuGood At
1
There are 1 best solutions below
Related Questions in PYTHON
- How to store a date/time in sqlite (or something similar to a date)
- Instagrapi recently showing HTTPError and UnknownError
- How to Retrieve Data from an MySQL Database and Display it in a GUI?
- How to create a regular expression to partition a string that terminates in either ": 45" or ",", without the ": "
- Python Geopandas unable to convert latitude longitude to points
- Influence of Unused FFN on Model Accuracy in PyTorch
- Seeking Python Libraries for Removing Extraneous Characters and Spaces in Text
- Writes to child subprocess.Popen.stdin don't work from within process group?
- Conda has two different python binarys (python and python3) with the same version for a single environment. Why?
- Problem with add new attribute in table with BOTO3 on python
- Can't install packages in python conda environment
- Setting diagonal of a matrix to zero
- List of numbers converted to list of strings to iterate over it. But receiving TypeError messages
- Basic Python Question: Shortening If Statements
- Python and regex, can't understand why some words are left out of the match
Related Questions in BACKSPACE
- i have a select2 and when i select multiple option and press backspace or unselect an option it unselects all options what should i do?
- Remove backspaces and corresponding characters from file
- Backspace stopped working in any JTextField in Java Swing after adding the custom class for IP text field with KeyListener added to it and only to it
- Can automatic press backspace when scanning barcodes in the textbox on the vb.net
- Why does Emacs turn TAB (\t) into multiple spaces when backspacing?
- Python readline delete the printed content line on double clicking backspace
- How to get rid of backspace in a log file made the bash program "script"?
- Angular 11 two way binding for a numeric field: backspace not working as expected and giving junk values whenever pressed
- golang ssh write backspace to stdin
- Back space function for python gui calculator to clear most recent input for example 435 delete 5 and show 43
- Is there a way to print a backspace in Python without using \b?
- Detecting Backspace click on Key_Down event in Android soft keyboard
- Is there a Unicode character that acts like a backspace or is invisible?
- Centos 7, Python shell witch actived virtual envirometn dont recognize backspace instead put H^
- Avoid deleting entire input value on backspace
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?
The problem is running the script in your IDE, whose terminal (apparently) doesn't support backspacing to erase characters (it's not unusual in this; the IDLE IDE that ships with Python doesn't support backspaces in output either). Run it in a regular terminal (e.g.
cmd.exeon Windows,bashor the like on a standard *NIX terminal), and printing'\b'works. It's all up to the terminal how it supports (or doesn't support) backspacing.For the record, you'd want to use either:
or:
to avoid the trailing newline (backspacing over a character shouldn't force you to the next line as a side-effect).