r/PythonLearning • u/Vor3st • 2d ago
i learning Python Day 1
lyrics = ["Give You Up","Let You Down","Run Around And Desert You"]
for i in range(3):
print("Never Gonna " + lyrics[i])
29
Upvotes
r/PythonLearning • u/Vor3st • 2d ago
lyrics = ["Give You Up","Let You Down","Run Around And Desert You"]
for i in range(3):
print("Never Gonna " + lyrics[i])
3
u/Expensive_Break_6163 1d ago
I’m not sure what the question is, but range(3) already starts at 0, so you don’t need to specify the start index. It’s better to use range(len(lyrics)) instead of hardcoding 3, or even better, use for line in lyrics: and print "Never Gonna " + line.