0
Code coach question
Trying to solve the problem, but my solution doesn't work Tom has done pull ups every day and recorded his results. He recorded each day's results in a new line, so that each line represents each day he has done pull ups. Create a program that takes n number as input and outputs the n-th days result (starting from 0). Sample Input 4 Sample Output Day 4, 9 pull ups file = open("simple.txt", "r") n = int(input()) for line in file.readlines(n): print(line) file.close() help me please, thanks
3 Answers
+ 1
Plz attached this code here
ĐŃ
Đ°Đ˝ it is free
here why are you use file
d=int(input ())
p=0
for i in range(0,d)
p+=I
print (p)
0
SĂĽĂątĂśsh
file = open("simple.txt", "r")
n = int(input())
for line in file.readlines(n):
print(line)
file.close()
0
SĂĽĂątĂśsh doesn't work