Answers for "number of elements list python"

1

how to find the amount of numbers in a list on python

>>> someList=[]
>>> print len(someList)
0
Posted by: Guest on May-15-2020
1

number of elements list python

>>> mylist = [1,2,3] #list
>>> len(mylist)
3
>>> word = 'hello' # string 
>>> len(word)
5
>>> vals = {'a':1,'b':2} #dictionary
>>> len(vals)
2
>>> tup = (4,5,6) # tuple 
>>> len(tup)
3
Posted by: Guest on October-16-2020
3

number of elements in list in python

# List of strings
listOfElems = ['Hello', 'Ok', 'is', 'Ok', 'test', 'this', 'is', 'a', 'test']
len(s)
Posted by: Guest on May-23-2020

Code answers related to "number of elements list python"

Python Answers by Framework

Browse Popular Code Answers by Language