Algorithm to read cost price and selling price and find whether profit or loss

1. Start.

2. Read cost price and selling price.

3.If cost price <0 or selling price < 0,
display invalid input. Go to step 7.

4. If cost price > selling price then, Profit. Go to step 7.

5. Else if selling > cost price then ,Loss. Go to step 7.

6. Else ,Neither profit nor loss.

7. End.

No comments:

Post a Comment