Java program to store temperatures in two-dimensional array

Assignment Help JAVA Programming
Reference no: EM1370757

Write a Java program that uses a two-dimensional array to store the highest and lowest temperatures for each month of the year. The program should output the average high,average low, and highest and lowest temperatures of the year. Your program must consist of the following methods:

getData- this method reads and stores the data in the two-dimensional array.

averageHigh- This method calculates and returns the average high temperature of the year.

averageLow- This method calculates and returns the average low temperature of the year.

indexHighTemp- This method returns the index of the highest temperatures in the array

indexLowTemp- This method returns the index of the lowest temperature of the array.

For this problem, you should provide two options for the user:
(1) To read data (i.e. the pair of input numbers) from a file, and then send results to a file
(2) To read data from the command line, and display results on the screen
(3) These options should be provided as a GUI dialog box, for example using the JOptionPane class.

Reference no: EM1370757

Questions Cloud

Concept of monopoly welfare loss : Compute the profit maximization level of activity. Compute  total revenue, total cot and profit or loss at profit maximization level of activity. Compute elasticity of demand at profit maximization. Compute the breakeven level of activity.
Find the total amount of cash reserves : Suppose the public in Nealland does not hold any cash. All commercial banks, however, hold 5 percent of their checking deposits as excess reserves, regardless of the interest rate.
Explain what does silence during communication indicate : Explain What does silence during communication indicate to you personally and How is your culture's use of silence connected to Hall's cultural patterns of low and high context
Most important factor to teach things : Upbringing is a factor that "burns with fire" in us to teach things that we are going to keep in the future. Explain
Java program to store temperatures in two-dimensional array : Write the Java program which uses two-dimensional array to store highest and lowest temperatures for each month of the year. Program must output average high,average low,
Compute the minimum amount of energy : Let the x axis be parallel to the ground, +y direction be vertically upward, and take as an origin the point on the ground directly below the top of the ramp.
Find firm profit-maximizing price and quantity : Find firm's profit-maximizing price and quantity. Illustrate what is profit. firm's production manager claims that firm's average cost of production is minimized at an output of 40 units.
Question related to training : How can an organization impart training to users on the analytical and proper utilization of data in a Decision Support System? Please explain.
Calculate required reserve ratio : Karen has kept her entire life savings, $50,000, in a floor safe underneath her bed. This morning, she make a decision to deposit her savings in a checking account at Cambridge Bank.

Reviews

Write a Review

JAVA Programming Questions & Answers

  Java applet to find how much federal tax we need to pay

Write a java applet to determine how much federal tax we need to pay assuming the tax rate is 12%.  Ask the taxable income.

  Implement a class quiz

Implement a class Quiz that implements the Measurable interface.

  Write a java applet for grade of gas in costco gas station

Write a java applet (not a java application program) for costco gas station. The applet will first ask you whether you are a costco customer, then the grade of gas you want to use.

  Implement the lexical and syntactic analysis

Implement the lexical and syntactic analysis of Minifun programming language.

  Write a java program to implement the finite field

Write a program called "GF2.java" to implement the finite field GF(p n ) where p is a prime number and n is a positive integer.  You also need to write four methods to realize "+", "-", "´", and "/".

  Dijikstra for undirected graph using simple scheme

Dijikstra for undirected graph using simple scheme with array and fibonacci heap and compare the performance/results, preferably in java.

  Develop a reliable transfer protocol over udp

Develop a reliable transfer protocol over UDP. Focus on a Stop- and-Wait protocol.

  Design and implement a small and simple email server

Design and implement a small and simple email server

  Write a java program in a netbeans project

Write a Java program in a NetBeans project

  Implement security so that all users can view the informatio

Implement security so that all users can view the information about the projects, but only authenticated users

  Java program which demonstrates cellular automata

Using the internet, locate a Java program (or Java applet) which demonstrates "Cellular Automata", in particular "the Game of Life".

  Build the gui layout of the game

Build the Build the GUI layout of the game in java.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd