Write a method printOdds1To11 that prints the odd numbers between 1 and 11 inclusive, one on each line. The program should calculate the odd numbers in a loop. The program text should not include the digits 3, 5, 7, or 9, but it will print these numbers out using System.out.println along with 1 and 11, in numerical order. It should only contain a single println statement. The program should take no arguments and return no value, just print things out.

Solved
Show answers

Ask an AI advisor a question