Timeline for Slowly turn a string into another
Current License: CC BY-SA 3.0
6 events
| when toggle format | what | by | license | comment | |
|---|---|---|---|---|---|
| Sep 4, 2016 at 12:25 | comment | added | clismique | You could change the second line to for i in range(x):print x[-i:], and the fourth line to for i in range(1,y):print y[:-i]. Not sure it would work, though. | |
| Sep 4, 2016 at 11:41 | comment | added | LevitatingLion | You can drop the second input() and use an input format like "<str1>", "<str2>" | |
| Sep 4, 2016 at 11:36 | history | edited | atlasologist | CC BY-SA 3.0 | deleted 16 characters in body |
| Sep 4, 2016 at 11:09 | history | edited | atlasologist | CC BY-SA 3.0 | added 75 characters in body |
| Sep 4, 2016 at 2:02 | comment | added | Jonathan Allan | No need for the len(x) in x=x[:len(x)-1] since negative offset slicing works - you can just write x=x[:-1]. Only problem is your code wont handle the " ", " " test case very well. | |
| Sep 4, 2016 at 1:16 | history | answered | atlasologist | CC BY-SA 3.0 |