Q. To check if a number is a positive or negative number.


Answer :-

Algorithm :-

1. Start
2. Input number
3. If number < 0
             Print "number is negative"
     Else
             Print "number is positive"
4. Stop

Pseudocode :-

N = input "A number "
If n is smaller than 0
       Display " n is negative number "
Else
        Display " n is positive number "

Flow Chart :-



Click on image for clear view.

Post a Comment

You can help us by Clicking on ads. ^_^
Please do not send spam comment : )

Previous Post Next Post