my recent post was already solved tnx for all the help guys

but im getting stuck again regarding on that the same problem,the program must display how many DECIMAL PLACES a number has. (e.g I entered number20 on num1,so it should display that " THE FIRST NUMBER HAS TWO DECIMAL PLACES and so on...)

"BUT" if i entered negative it should display
"CANNOT PROCEED"
i should only type numbers who are not negative.

I used if-else statement:

if (num1<=9) // this would tell that the numbers from 9 below have only 1 decimal place.

else if (num1<=99) // also, this would tell that numbers from 99 below have 2 decimal places

but what am i going to do if i entered negative numbers
i tried this

if (num1<0) and i tried this one (num1<= -1)
i doesnt work.

anyway my problem is not SYNTAX ERROR.
im stuck with some LOGICAL ERRORS.

hope anyone can help me again here

tnx guys!!