Write an algorithm and draw a flowchart to print prime numbers from 1 to 50

By Eden

Write an algorithm and draw a flowchart to print prime numbers from 1 to 50

About the author
Eden

1 thought on “Write an algorithm and draw a flowchart to print prime numbers from 1 to 50”

  1. Few prime number are − 1, 2, 3, 5 , 7, 11 etc.

    • Algorithm. Algorithm of this program is very easy − START Step 1 → Take integer variable A Step 2 → Divide the variable A with (A-1 to 2) Step 3 → If A is divisible by any value (A-1 to 2) it is not prime Step 4 → Else it is prime STOp
    Reply

Leave a Reply to Gabriella Cancel reply