solution:
Given data:
Code :
require 'csv' #required to read the data in csv file
table = CSV.parse(File.read("input.csv"), headers: true) # reads a file input.csv and creates a table of data
puts "Student Assignment Average" #output line as
described in question
$i = 0 #will be used for iterating the table
$length = table.length() #stores number of students in
table
$assignments = table[0].length()-1 #stores number of
assignments
while $i < $length do #loop over each student
record
$j = 0
$sum = 0.0 #initilize sum to 0.0
while $j < $assignments do #loop over
each assignment of a particular student
$sum = $sum +
(table[$i][$j+1]).to_f #add the grade to sum
$j += 1
end
puts table[$i][0] + " " +
(($sum/$assignments).round(1)).to_s #display name and
average grade of students
$i +=1
end
Code screenshot :

input file :

output screenshot :

thank you .....................
please give me thumb up
Wk 4 - Write a Ruby Program (due Mon] Assignment Content The college IT department manager...
The college IT department manager no longer wants to use spreadsheets to calculate grades. The manager has asked you to create a program that will input the teachers' files and output the students' grades. Write a Ruby program named format file.rb, which can be run by typing ruby widgets.rb. In your Ruby environment, the program must read an input file formatted in CSV format, named input.csv. Each record contains data about a student and their corresponding grades. The data will...
I need this in Python Please! The college IT department manager no longer wants to use spreadsheets to calculate grades. The manager has asked you to create a program that will input the teachers' files and output the students' grades. In your Python environment, the program must read an input file formatted in CSV format, named input.csv. Each record contains data about a student and their corresponding grades. The data will look similar to the following: Student Name, assignment 1,...
Write a C++ program that computes student grades for an assignment as a percentage given each student's score and the total points. The final score must be rounded up to the nearest whole value using the ceil function in the <cmath header file and displayed as a percentage. You must also display the floating-point result up to 5 decimal places. You must use at least 2 functions: one to print the last name of the student and another function to...
In this assignment, you will write a program in C++ which uses files and nested loops to create a file from the quiz grades entered by the user, then reads the grades from the file and calculates each student’s average grade and the average quiz grade for the class. Each student takes 6 quizzes (unknown number of students). Use a nested loop to write each student’s quiz grades to a file. Then read the data from the file in order...
Lab Exercise #15 Assignment Overview This lab exercise provides practice with Pandas data analysis library. Data Files We provide three comma-separated-value file, scores.csv , college_scorecard.csv, and mpg.csv. The first file is list of a few students and their exam grades. The second file includes data from 1996 through 2016 for all undergraduate degree-granting institutions of higher education. The data about the institution will help the students to make decision about the institution for their higher education such as student completion,...