Question: Java program please Create a class called HW1Problem2. Create the following (public) methods in the class: Write a method called multiple that takes two integers
Java program please
Create a class called HW1Problem2. Create the following (public) methods in the class: Write a method called multiple that takes two integers as its arguments and returns true if the first integer is divisible evenly by the second one (i.e., there is no remainder after division); otherwise, the method should return false Write a method called reminder that takes an integer as an argument and returns the remainder of that value divided by 7 Write method distance to calculate the distance between two points (x1, y1) and (x2, y2). All numbers and return values should be of type double. BONUS: Write a method that uses random numbers to simulate 10 flips of a coin. 1. 2. 3. 4. Incorporate all of the above methods in a driver class Problem2Driver. Allow user to provide inputs for the arguments of the methods and also display results from the methods
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
