catower
Split this topic
December 28, 2019, 12:08am
66
3 posts were merged into an existing topic: Sharing solutions
catower
Split this topic
December 28, 2019, 12:18am
69
2 posts were split to a new topic: Why doesn’t this code work?
catower
Split this topic
December 28, 2019, 12:23am
71
4 posts were split to a new topic: Is this code okay?
catower
Split this topic
December 28, 2019, 12:24am
75
3 posts were merged into an existing topic: How can I iterate over a list backward?
catower
Split this topic
December 28, 2019, 12:25am
80
2 posts were merged into an existing topic: Sharing solutions
catower
Split this topic
December 28, 2019, 12:43am
87
2 posts were split to a new topic: What do you think of this solution?
catower
Split this topic
December 28, 2019, 12:57am
92
3 posts were merged into an existing topic: How can I iterate over a list backward?
catower
Split this topic
December 28, 2019, 1:12am
95
12 posts were merged into an existing topic: Did you double check the placement of return
?
catower
Split this topic
December 28, 2019, 1:18am
107
3 posts were split to a new topic: Why doesn’t this code work?
catower
Split this topic
December 28, 2019, 1:26am
111
catower
Split this topic
December 28, 2019, 1:26am
116
2 posts were split to a new topic: Why don’t we use else?
catower
Split this topic
December 28, 2019, 1:28am
118
catower
Split this topic
December 28, 2019, 1:30am
128
catower
Split this topic
December 28, 2019, 1:37am
130
catower
Split this topic
December 28, 2019, 1:39am
133
5 posts were split to a new topic: Boredless tourist question?
catower
Split this topic
December 28, 2019, 1:42am
138
catower
Split this topic
December 28, 2019, 1:43am
140
A post was split to a new topic: The next lesson won’t load?
catower
Split this topic
December 28, 2019, 1:45am
146
catower
Split this topic
December 28, 2019, 1:47am
149
A post was merged into an existing topic: Sharing solutions
I don’t understand the logic here, can someone explain why my code is wrong?
Thanks a lot!
def reversed_list(lst1, lst2):
#lst1[0] = lst2[-1]
#lst1[1] = lst2[-2]
#lst1[2] = lst2[-3]
for index in range(len(lst1)):
for index in range(len(lst2)):
if (lst1[index] == lst2[-1-index]):
return True
else:
return False