lets learn python basics

1 Lecture of python basics
so guys if you want this type of series then please comment on it i will strongly suggest you some
site where you can learn the python .
with that site you can solve your query and thier is many more sites available .
 in basic their are some statements
1. looping statement  
    * for loop *
    * while loop *
    * for in loop *
firstly we learn the for loop statement :-
  1 type code:-
      fruits = ["apple", "banana", "cherry"]
      for x in fruits:
      print(x)
  output:-
        C:\Users\My Name>python demo_for.py
         apple
        banana
        cherry
 2 type code:-
       for x in "banana":
       print(x)
   output:-
       C:\Users\My Name>python demo_for_string.py
        b
        a
        n
        a
        n
        a 

Comments

Popular posts from this blog

Python Class and Objects

exception handling in python

Fibonacci series in python