题解 | #截取字符串#人生苦短,我用Python啊
截取字符串
http://www.nowcoder.com/practice/a30bbc1a0aca4c27b86dd88868de4a4a
while True:
try:
str_input = input()
k = int(input())
print(str_input[:k])
except:
break
try:
str_input = input()
k = int(input())
print(str_input[:k])
except:
break