python
查看原帖
python
929490
loren111楼主2023/2/26 15:13

target = ' ' + input().lower() + ' ' graph = ' ' + input().lower() + ' ' if graph.find(target) != -1: print(graph.count(target) + graph.count(target.rstrip() + target), graph.find(target)) else: print(-1)

graph.count(target.rstrip() + target) # 为啥要加这句话,前面的count不是已经计算完了嘛

2023/2/26 15:13
加载中...