f=lambda s:f(s[:-1])+[s]if s else[] i=input() print(f(i))
נחמן
['נ', 'נח', 'נחמ', 'נחמן']
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!