Skip to content

Instantly share code, notes, and snippets.

@codecademydev
Created April 20, 2020 18:07
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save codecademydev/93b16efebf40776a3aa645a9f0ea14be to your computer and use it in GitHub Desktop.
Save codecademydev/93b16efebf40776a3aa645a9f0ea14be to your computer and use it in GitHub Desktop.
Codecademy export
#Write your function here
def reversed_list(lst1, lst2):
boo1 = True
for i in range(len(lst1)):
if lst1[i] != lst2[-1-i]:
boo1 = False
break
return boo1
#Uncomment the lines below when your function is done
print(reversed_list([1, 2, 3], [3, 2, 1]))
print(reversed_list([1, 5, 3], [3, 2, 1]))
print(reversed_list([1, 5, 3], [3, 5, 1]))
print(reversed_list([2, 5, 3], [3, 2, 1]))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment