Question: In Java. 1. Declare an object of Scanner, and ask user to input an 8-digits integer. ii) Reverse the order of the digits for the
In Java.
1. Declare an object of Scanner, and ask user to input an 8-digits integer.
ii) Reverse the order of the digits for the first-four digits and last-four digits.
(E.g., if the input is 12345678, the expected output will be 43218765)
2.
Define an object of Scanner named "console", and ask users to input two integers "a" and "b".
ii) Create a method named Rectangle(int a, int b) which will prints a rectangle. The length and width of such a rectangle is "a" and "b" as user inputted.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
