Computer Science, asked by srikanth305, 3 months ago

What is the output of the below program?

a = [1,2,3,None,(),[],]

print len(a)

Answers

Answered by racharlashivani53
1

Answer:

in Python prompt, len(a) # prints 6

in Python program,

print len(a) # this gives Compilation error

print(len(6)) # prints 6

Answered by yogeshkumar49685
1

Concept:

Python lists are one of the most versatile data formats for working with several elements at the same time. There can be any number of entries in a list, and they can be of many types (integer, float, string, etc.). Place elements inside square brackets to make a list.

Program:

The length of the list.

Solution:

The total elements in the list variable is 6.

Hence, the length of the list is 6

Similar questions