53 Program for function to print elements of a list in Python

Program:

#function to print elements of a list



x=[10,20,30,40,50]

def display():

    for p in x:

        print(p)

display()


Output:
      Program for function to print elements of a list in Python

Previous
Next Post »