Advertisement
Easy_Flex

Untitled

Feb 22nd, 2020
106
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.30 KB | None | 0 0
  1. empty = []
  2. active = [True]
  3. favorite_numbers = [1, 2, 3, 4, 5]
  4. colors = ["red", "green", "blue"]
  5.  
  6.  
  7. def is_long(variable):
  8.     # Iteration to check if the list has more than 5 elements
  9.     if len(variable) > 5:
  10.         return True
  11.  
  12.     else:
  13.         return False
  14.  
  15.  
  16. print(is_long([1, 2, 3, 4, 5, 6])
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement