Menu
Coddy logo textTech

Recap Challenge #1

Lesson 6 of 16 in Coddy's Strings and Arrays in Java course.

challenge icon

Challenge

Easy

Write a function named isNumber that gets a string s and returns true if all the characters in s are numbers (0 - 9), otherwise false.

Try it yourself

class IsNumber {
    public static boolean isNumber(String s) {
        // Write code here
    }
}

All lessons in Strings and Arrays in Java