Java A file USPopulation.txt contains the population of the US starting in year 1950 and then each subsequent record has the population for the following year. USPopulation.txtDownload USPopulation.txt Write a program that uses an array with the file that displays these in a menu and then produces the results. This is not an Object Oriented Program but should be a procedural program, calling methods to do the following: 1: Displays the year and the population during that year 2. The average population during that time period (Add up the populations of all records and divide by the number of years). 3. The year with the greatest increase in population - print the year and that population and that amount. To figure this out, compare the difference in population before of say year 1950 and 1951, store that difference somewhere. Compare 1951 with 1952, find that difference. Is that difference greater than the stored difference? If so, move that the the maximum place. 4. Print the year and population in reverse order with most current until oldest here is the file  151868 153982 156393 158956 161884 165069 168088 171187 174149 177135 179979 182992 185771 188483 191141 193526 195576 197457 199399 201385 203984 206827 209284 211357 213342 215465 217563 219760 222095 224567 227225 229466 231664 233792 235825 237924 240133 242289 244499 246819 249623

Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
icon
Related questions
Question

Java

A file USPopulation.txt contains the population of the US starting in year 1950 and then each subsequent record has the population for the following year. USPopulation.txtDownload USPopulation.txt Write a program that uses an array with the file that displays these in a menu and then produces the results. This is not an Object Oriented Program but should be a procedural program, calling methods to do the following: 1: Displays the year and the population during that year 2. The average population during that time period (Add up the populations of all records and divide by the number of years). 3. The year with the greatest increase in population - print the year and that population and that amount. To figure this out, compare the difference in population before of say year 1950 and 1951, store that difference somewhere. Compare 1951 with 1952, find that difference. Is that difference greater than the stored difference? If so, move that the the maximum place. 4. Print the year and population in reverse order with most current until oldest

here is the file 

151868
153982
156393
158956
161884
165069
168088
171187
174149
177135
179979
182992
185771
188483
191141
193526
195576
197457
199399
201385
203984
206827
209284
211357
213342
215465
217563
219760
222095
224567
227225
229466
231664
233792
235825
237924
240133
242289
244499
246819
249623

Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 4 steps with 8 images

Blurred answer
Knowledge Booster
Array
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
Recommended textbooks for you
Database System Concepts
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
Starting Out with Python (4th Edition)
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
C How to Program (8th Edition)
C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
Programmable Logic Controllers
Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education