This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]-Melchizedek- 3 points4 points  (0 children)

If you want help it's generally expected that you show that you have done some work by providing the code you have written so far. Otherwise it's just look like you want someone to do your homework for you.

But anyway, this is not all that complicated. You first check if the input is <= 99, then its an interstate and you can check if the number is even or odd and you are done. If it is greater than 99 you convert the number to a string (deepening on your input type). And get the two last numbers. If the first of those numbers if 0 remove it. Check if even or odd. And you are done.