| about | help | done | prefs | create account |
AP-1 > hasOne
prev | next | chance
| Given a positive int n, return true if it contains a 1 digit. Note: use % to get the rightmost digit, and / to discard the rightmost digit.
hasOne(10) → true hasOne(22) → false hasOne(220) → false ...Save, Compile, Run See Also: Example Code Java help: If Boolean Logic | Strings | While and For Loops | Arrays and Loops |
Forget It! -- delete my code for this problem 224.0
Copyright Nick Parlante 2006-09 - privacy