My favorite recent find in iPython is “alt-9-backspace” which deletes 9 “words” back. In my case clearing a uuid string in a Django ORM query:
MyModel.objects.filter(UUID=‘123e4567-e89b-12d3-a456-426655440000‘)
MyModel.objects.filter(UUID=‘123e4567-e89b-12d3-a456-426655440000‘)
The number doesn't have to be a single digit, so Alt-3, Alt-6, Backspace, or Alt-3, Alt-6, Ctrl-H also work (delete 36 characters.)
(Your command would normally be described is Alt-9, Alt-Backspace; or M-9 M-Backspace; to show the Alt/"Meta" key is held for both strokes.)