This example uses recursion to count in base 2. A base 2 number name is represented by a String of 0's and 1's. The static method count takes a binary name as input and returns the name for the next number as output. The method is tested in a main that counts to one thousand in binary. Here is the documentation, and here is the source code to test it out: