Write a program which finds the maximum and minimum of a set of Hoats stored in the You can assume that the number of values in the input file is less than samplesin.txt. Your main must use the following steps: • open the two files samplesin.txt and maxminout.txt. . read the values from samplesin.txt into the array x. • compute the maximum and minimum values found in the array x. walion to the filo mayminout tyt

EBK JAVA PROGRAMMING
9th Edition
ISBN:9781337671385
Author:FARRELL
Publisher:FARRELL
Chapter13: File Input And Output
Section: Chapter Questions
Problem 6PE
icon
Related questions
Question
Plz use c programming to solve this question. Plz don't use a library other than # include < stdio. h > and # include math . h and # define n 100
Write a program which finds the maximum and minimum of a set of floats stored in the file
samplesin.txt. You can assume that the number of values in the input file is less than 100.
Your main must use the following steps:
• open the two files samplesin.txt and maxminout.txt.
. read the values from samplesin. txt into the array x.
• compute the maximum and minimum values found in the array x.
. write the maximum and minimum values to the file maxminout.txt.
Your program output file should look like:
There are 80 values in the array
The maximum value in the array is 63.605999
The minimum value in the array is 4.808900
Transcribed Image Text:Write a program which finds the maximum and minimum of a set of floats stored in the file samplesin.txt. You can assume that the number of values in the input file is less than 100. Your main must use the following steps: • open the two files samplesin.txt and maxminout.txt. . read the values from samplesin. txt into the array x. • compute the maximum and minimum values found in the array x. . write the maximum and minimum values to the file maxminout.txt. Your program output file should look like: There are 80 values in the array The maximum value in the array is 63.605999 The minimum value in the array is 4.808900
Expert Solution
steps

Step by step

Solved in 4 steps with 2 images

Blurred answer
Knowledge Booster
Constants and Variables
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
  • SEE MORE QUESTIONS
Recommended textbooks for you
EBK JAVA PROGRAMMING
EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781337671385
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT