Discussion on Week 2's Topic

Discussion topics of Second weeks are:-

Discussion topics of Second weeks are:-

by Fateha Nasrin 181-15-1900 -
Number of replies: 0

How we use arithmetic operators , loops and conditional statements in python?
Arithmetic operators are used to perform mathematical operations like addition, subtraction, multiplication and division.
example: 
                x=20
                y=10
                z= x + y
                print(z)
                z=x * y
                print(z)
                etc.
The for loop in Python is used to iterate over a sequence (list, tuple, string) or other iterable objects. Iterating over a sequence is called traversal.
example:
               for n range(10)
                     print(n)

              j = 1
            while j < 6:
                print(j)
                 j+= 1
Conditional Statement in Python perform different computations or actions depending on whether a specific Boolean constraint evaluates to true or false. Conditional statements are handled by IF statements in Python.
example:
              if expression
          Statement
        else 
          Statement