Ask Question
6 August, 09:46

my homework guides Write the definition of a method printDottedLine, which has no parameters and doesn't return anything. The method prints to standard output a single line (terminated by a newline) consisting of five periods.

+5
Answers (1)
  1. 6 August, 12:26
    0
    public static void printDottedLine () {

    System. out. print (" ... / n");

    }

    Explanation:

    This method returns nothing so its return type is void

    It also accepts no parameters so the argument list is empty

    When called it executes the System. out. print (" ... / n"); which prints out 5 dots

    See a complete program below:

    public class TestClock {

    public static void main (String[] args) {

    printDottedLine ();

    }

    public static void printDottedLine () {

    System. out. print (" ... / n");

    }

    }
Know the Answer?
Not Sure About the Answer?
Find an answer to your question ✅ “my homework guides Write the definition of a method printDottedLine, which has no parameters and doesn't return anything. The method prints ...” in 📘 Computers and Technology if you're in doubt about the correctness of the answers or there's no answer, then try to use the smart search and find answers to the similar questions.
Search for Other Answers