COSc-1337-002> Assignments> Assignment 3 g 2019 Assignment 3 me signments ades labus Due Friday by 11:59pm Points 100 Subm A3-Arrays 2 "2D Array Operations" izzes Access A3 from pdf assionment file e. dules Turn in the following files: a3main.java ArrayOperations2D.java program compile and run screenshots design document dent Survey Al 12. Coln Toss Simulator Write a class named coin. The coin class should have the following field: . A string named sidep. The sideup field will hold either "heads" or "tails" indicating the side of the coin that is facing up. The Coin class should have the following methods: . A no-arg constructor that randomly determines the side of the coin that is facing up "heads" or "tails") and initializes the sideup field accordingly . A void method named toss that simulates the tossing of the coin. When the toss method is called, it randomly determines the side of the coin that is facing up ("heads" or "tails") and sets the sideUp field accordingly . A method named getsideip that returns the value of the sidedp field. Write a program that demonstrates the coin class. The program should create an instance of the class and display the side that is initially facing up. Then, use a loop to toss the coin 20 times. Each time the coin is tossed, display the side that is facing up. The program should keep count of the number of times heads is facing up and the number of times tails is facing up, and display those values after the loop finishes. 13. Tossing Coins for a Dollar For this assignment you will create a game program using the coin class from Programming Challenge 12. The program should have three instances of the coin class: one representing a quarter, one representing a dime, and one representing a nickel. When the game begins, your starting balance is S0. During each round of the game, the program will toss the simulared coins. When a coin is tossed, the value of the coin is added to your balance if it lands heads up. For example, if the quarter lands heads-up, 25 cents is added to your balance. Nothing is added to your balance for coins that land tails-up. The game is over when your balance reaches one dollar or more. If your balance is exactly one dollar, you win the game. You lose if your balance exceeds one dollar Hi e 15. 2D Array Operations Write a program that creates a two-dimensional array initialized with test data. Use any primitive data type that you wish. The program should have the following methods: . getrotal. This method should accept a two-dimensional array as its argument and return the total of all the values in the array getAverage. This method should accept a two-dimensional array as its argument and return the average of all the values in the array . getRovTotal. This method should accept a two-dimensional array as its first argu- ment and an integer as its second argument. The second argument should be the sub- script of a row in the array. The method should return the total of the values in the specified row. . getcolumnTotal. This method should accept a two-dimensional array as its first a ment and an integer as its second argument. The second argument should be the sub- script of a column in the array. The method should return the total of the values in the specified column. . getHighestInRow. This method should accept a two-dimensional array as its first argument and an integer as its second argument. The second argument should be the subscript of a row in the array. The method should return the highest value in the specified row of the array getLowest InRow. This method should accept a two-dimensional array as its first argu- ment and an integer as its second argument. The second argument should be the sub script of a row in the array. The method should return the lowest value in the specified row of the array Demonstrate each of the methods in this program