how to empty Array in python
- Last modified: 05 March 2020
- Category: python tutorial
example
1 2 3 4 5 6 7 8 | #array array = ['cat', 'dog', 'zebra'] #empty array array = [] #print array print(array) |
output
1 | []
|
cheking if array is empty
1 2 | if len(array) == 0: print('yes! array is empty') |
output
yes! array is empty
English today is not an art to be mastered it's just a tool to use to get a result