CJCoding With Joseph
15per day

Write a Generic Method to Print Two Items

Complete the generic static method printTwoItems that takes two values of the same type and prints each one on its own line.

IMPORTANT: Do NOT write a main method. A hidden test will call Printer.printTwoItems('A', 'B') and Printer.printTwoItems(5, 10) and verify each value prints on its own line.

Expected Output:
A
B
5
10

Expected Output:

A
B
5
10
Topics:
GenericsMethods
Code Editor
1
Tab to indent ยท Ctrl+Enter to run ยท Ctrl+Space to expand shortcuts (sysout, psvm, fori)

Your Output

Run your code to see the output here...

Test Cases

Run your code to see test case results.