Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
You shouldn't print the result, you should return it
you are supposed to return the results, not print them
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
Got the right outputs, whats wrong with my code?
def arr(n):
if n > 0:
a = list(range(0,n))
print(a)
elif n == 0:
a = list(0)
print(a)
else:
a = list()
print(a)
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution