Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Can you make this as simple as possible in Java? No arrays or try as we haven't covered them yet. I'm really struggling and need
Can you make this as simple as possible in Java? No arrays or try as we haven't covered them yet. I'm really struggling and need this to be done in the least complicated way.
2. Write a program that asks the user to enter the name of a file that contains a set of integer values, and then asks the user to enter an integer number. The program should display the average of the numbers that are greater than the input number. User Notepad or another text editor to create a simple file that can be used to test the program. First, the user enters the file name as below: Enter the file name: myText.txt and if, for example, the file 'mytext.txt' contains the following numbers 30 23 56 43 32 35 90 12 and then, if the user enters an integer number, as The number to check: 40 the program should display the output as The average of the numbers that are greater than 40 is 58.25 Note that average of numbers 44, 56, 43 and 90 is 2334-5825. The average must be shown up to two decimal points. (Hint: DecimalFormat class can be used) If the input file is not found, the user must be prompted to enter the filename again with the following message "File is not found, enter the filename againStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started