python get the length of a list
studentGrades = [9.1, 8.8, 10.0, 7.7, 6.8, 8.0, 10.0, 8.1, 10.0, 9.9]
print(len(studentGrades))
python get the length of a list
studentGrades = [9.1, 8.8, 10.0, 7.7, 6.8, 8.0, 10.0, 8.1, 10.0, 9.9]
print(len(studentGrades))
how to get size of list in python
list_1 = ["Hello", 1, "World", 2]
# if you want length of this lins use len() function
print(len(list_1))
# if you want size in bytes
import sys
print(sys.getsizeof(list_1), "Bytes")
how to find length of list python
my_list = [1,2,3,4,5,6,7,8,9,10]
length_of_list = len(my_list)
python list of size
li = [None] * 5 # [None, None, None, None, None]
li = [0] * 5 # [0, 0, 0, 0, 0]
Copyright © 2021 Codeinu
Forgot your account's password or having trouble logging into your Account? Don't worry, we'll help you to get back your account. Enter your email address and we'll send you a recovery link to reset your password. If you are experiencing problems resetting your password contact us