How to add two or more number or alphabet in list?
Answers
Answered by
1
Answer:
Approach :
Read input number asking for length of the list using input() or raw_input() .
Initialise an empty list lst = [] .
Read each number using a for loop .
In the for loop append each number to the list.
Now we use predefined function sum() to find the sum of all the elements in a list.
Print the result.
Similar questions