What is Flow chart and how to use different symbols with examples

By
Flow chart:-Flow chart is a graphical representation of algorithms to solve the step by step problems in sequential manner.It uses different kinds of Boxes and arrows to represent the process.
There are following symbols are used in flow chart as given below:-
# Write a program to check weather number is even or odd.
Algorithm:-
  1. Start
  2. Input Number n
  3. if (n%2==0)
  4. display number is even
  5. else display number is odd
  6. Stop
Flow chart:-

Program:-
#Check weather number is even or odd
n=int(input("Enter a Number:\n"))
if(n%2==0):
    print("Given Number is Even Number")
else:
   print("Given Number is Odd Number")
Output of Above Python Code:-

0 comments:

Post a Comment

Powered by Blogger.