I need #5 done i cant seem to understand it. it must be written in c++


4)
random.txt (Save the file under D Drive.Then the path of the file pointing to it is D:\\random.txt )
23
45
32
99
89
33
77
99
11
39
92
56
_______________
#include <iostream>
#include <fstream>
using namespace std;
int main()
{
//Declaring variables
int number,option,count=0,i=0;
double sum=0.0,average;
//fileInput reference
ifstream dataIn;
//Opening input file
dataIn.open("D:\\random.txt");
//this loop conitinues to counts the number of elements in the
file
while(dataIn>>number)
{
count++;
}
//cout<<"Total No of Numbers in the file
:"<<count<<endl;
dataIn.close();
//Creating an integer array
int filearr[count];
//Opening input file
dataIn.open("D:\\random.txt");
/* This loop continues to executes until it
* iterates over every number in the file
*/
while(dataIn>>number)
{
//Getting the number from the file and populates into an
array
filearr[i]=number;
sum+=filearr[i];
//Incrementing the 'i' value by 1 every time
i++;
}
//calculating the average of all the numbers
average=sum/count;
//Displaying the results
cout<<"The number of numbers in the file
:"<<count<<endl;
cout<<"The sum of all numbers in the file
:"<<sum<<endl;
cout<<"The average of all the numbers in the file
:"<<average<<endl;
return 0;
}
__________________
Output:

_________________
5)
I need #5 done i cant seem to understand it. it must be written in c++...
I am in C++ programming, I need help with this assignments. The answer in this assignments when I look for it it doesn't work in my visual studios. Can you please help me? I hardly have C in the class, if I fail I will fail the whole class and repeat this class again. The file named Random.txt contains a long list of random numbers. Download the file to your system, then write a program that opens the file, reads...
USE C++ FOR THE CODE THAT CAN RUN IN VISUAL STUDIO 2019
(or a complier)
Ignore the last paragraph on the bottom of the
page!
\
Write a program YourName-Assignments (replace Your Name with your actual name, no spaces) that reads from students' records (one student per line) in the following format: Last Name Tests Grade Assignments Grade and computes and outputs (to the console) the STUDENT STATISTICS in a table format one line per student: Student Name Total Points...
Write a Java program that reads a file until the end of the file is encountered. The file consists of an unknown number of students' last names and their corresponding test scores. The scores should be integer values and be within the range of 0 to 100. The first line of the file is the number of tests taken by each student. You may assume the data on the file is valid. The program should display the student's name, average...
using C# Write a program which calculates student grades for multiple assignments as well as the per-assignment average. The user should first input the total number of assignments. Then, the user should enter the name of a student as well as a grade for each assignment. After entering the student the user should be asked to enter "Y" if there are more students to enter or "N" if there is not ("N" by default). The user should be able to...
programming language is C++. Please also provide an explanation of
how to create a file with the given information and how to use that
file in the program
Let's consider a file with the following student information: John Smith 99.0 Sarah Johnson 85.0 Jim Robinson 70.0 Mary Anderson 100.0 Michael Jackson 92.0 Each line in the file contains the first name, last name, and test score of a student. Write a program that prompts the user for the file name...
Program 5 Due 10/25 C-String and Two-dimensional Array Use An input data file starts with a student's name (on one line). Then, for each course the student took last semester, the file has 2 data lines. The course name is on the first line. The second line has the student's grade average (0 to 100) and the number of credits for the course Sample data: Jon P. Washington, Jr. Computer Science I 81 4 PreCalculus 75 3 Biology I 88...
This is a C++ Program, I need the program broken up into
Student.h, Student.cpp, GradeBook.h, GradeBook.cpp, and
Main.cpp
1. The system must be able to manage multiple students (max of 5) and their grades for assignments from three different assignment groups: homework (total of 5), quizzes (total (total of 2) of 4), and exams 2. For each student record, the user should be able to change the grade for any assignment These grades should be accessible to the gradebook for...
Using C++. Please Provide 4 Test Cases.
Test #
Valid / Invalid Data
Description of test
Input Value
Actual Output
Test Pass / Fail
1
Valid
Pass
2
Valid
Pass
3
Valid
Pass
4
Valid
Pass
Question 2 Consider a file with the following student information: John Smith 99 Sarah Johnson 85 Jim Robinson 70 Mary Anderson 100 Michael Jackson 92 Each line in the file contains the first name, last name, and test score of a student. Write a...
Please answer all the questions and I don't want work for
another person. do it in jaf project.
5.6 (Conversion from m to kilometers) Write a program that displays the following two tables side by side: Miles Miles Kilometers Kilometers 1.609 20 12.430 15.538 3.218 25 37.290 14.481 60 I 65 40.398 10 16.090 5.8 (Find the highest score) Write a program that prompts the user to enter the number of students and each student's name and score, and finally...
****THIS IS A 2 PART QUESTION! I ONLY NEED THE ANSWER TO PART 2
ON HOW TO SEND THE DATA SERIALIZED****
Write a c# program that stores student grades in a text file and
read grades from a text file. The program has the
following GUI:
There are four buttons: Create File, Save Case, Close File and
Load File. Initially, only the Create File and Load File
buttons are enabled. If the user clicks the Create File
button, a Save File Dialog window...