1

I'm trying to write a simple SSH python module. In this module I need to detect special characters like tab('\t'), enter('\n') and backspace('\b'). I managed to handle the autocomplete of tab on new line with enter. However, I cannot simply delete a character. if i try:

print('\b',end='',flush=True)

It will not delete the last character printed character but will ignore the next coming one. In C it's way simpler...

how can I delete already printed characters in a python console(in similar way its possible to delete characters in the built in module 'input')?

Eliav Louski
  • 1,877
  • 1
  • 15
  • 30

0 Answers0