For the end of year administration of Programming for History of Arts students you are to write a program that can do 2 things: calculate a final grade print a small graph of similarity scores and, if applicable, list the students under investigation The input is structured as follows: Piet van Gogh___5 6 7 4 5 6 5=20=22=10=2=0=0=1=0=1;Vincent Appel,Johannes Mondriaan Karel van Rijn___7 8 6 6 2=30=15=8=4=3=2=0=0=0; The first line should be interpreted as follows: You have to calculate the final grade of the student. All grades have the same weight. The final grade is rounded as follows: a grade that is >= 5.5 AND < 6 should be noted as a "6-" otherwise, a grade will be rounded to the nearest half The second line should be interpreted as follows: <10 numbers separated by '='>; The first 10 numbers are the similarity scores. These scores represent the number of programs matching a certain percentage of the current program in steps of 10%. This means the first numbers indicates the matches from 1%-10% and the last number indicates the matches from 91%-100%. Since this is not very readable, the professor would like a simple graph according to these rules:  if there are zero matches, display an underscore: _ if there are less than 20 matches, display a minus sign: - if there are 20 or more matches, display a caret: ∧ The names of the students after the semicolon are the names of the students with matches in the final 3 categories. The names of these students should be printed under the graph. If there are no matches, the program should print "No matches found". The output for the aforementioned input should be: Piet van Gogh has an average of 6- -^^--__-_- Vincent Appel Johannes Mondriaan Karel van Rijn has an average of 7.0 -^-----___

Computer Networking: A Top-Down Approach (7th Edition)
7th Edition
ISBN:9780133594140
Author:James Kurose, Keith Ross
Publisher:James Kurose, Keith Ross
Chapter1: Computer Networks And The Internet
Section: Chapter Questions
Problem R1RQ: What is the difference between a host and an end system? List several different types of end...
icon
Related questions
Question

For the end of year administration of Programming for History of Arts students you are to write a program that can do 2 things:

  1. calculate a final grade
  2. print a small graph of similarity scores and, if applicable, list the students under investigation

The input is structured as follows:

Piet van Gogh___5 6 7 4 5 6
5=20=22=10=2=0=0=1=0=1;Vincent Appel,Johannes Mondriaan
Karel van Rijn___7 8 6 6
2=30=15=8=4=3=2=0=0=0;

The first line should be interpreted as follows:

You have to calculate the final grade of the student. All grades have the same weight. The final grade is rounded as follows:

  • a grade that is >= 5.5 AND < 6 should be noted as a "6-"
  • otherwise, a grade will be rounded to the nearest half

The second line should be interpreted as follows:

<10 numbers separated by '='>;<zero or more names separated by ','>

The first 10 numbers are the similarity scores. These scores represent the number of programs matching a certain percentage of the current program in steps of 10%. This means the first numbers indicates the matches from 1%-10% and the last number indicates the matches from 91%-100%.

Since this is not very readable, the professor would like a simple graph according to these rules:

  •  if there are zero matches, display an underscore: _
  • if there are less than 20 matches, display a minus sign: -
  • if there are 20 or more matches, display a caret: ∧

The names of the students after the semicolon are the names of the students with matches in the final 3 categories. The names of these students should be printed under the graph. If there are no matches, the program should print "No matches found".

The output for the aforementioned input should be:

Piet van Gogh has an average of 6-
-^^--__-_-
Vincent Appel
Johannes Mondriaan

Karel van Rijn has an average of 7.0
-^-----___
No matches found

 

Expert Solution
steps

Step by step

Solved in 2 steps with 7 images

Blurred answer
Recommended textbooks for you
Computer Networking: A Top-Down Approach (7th Edi…
Computer Networking: A Top-Down Approach (7th Edi…
Computer Engineering
ISBN:
9780133594140
Author:
James Kurose, Keith Ross
Publisher:
PEARSON
Computer Organization and Design MIPS Edition, Fi…
Computer Organization and Design MIPS Edition, Fi…
Computer Engineering
ISBN:
9780124077263
Author:
David A. Patterson, John L. Hennessy
Publisher:
Elsevier Science
Network+ Guide to Networks (MindTap Course List)
Network+ Guide to Networks (MindTap Course List)
Computer Engineering
ISBN:
9781337569330
Author:
Jill West, Tamara Dean, Jean Andrews
Publisher:
Cengage Learning
Concepts of Database Management
Concepts of Database Management
Computer Engineering
ISBN:
9781337093422
Author:
Joy L. Starks, Philip J. Pratt, Mary Z. Last
Publisher:
Cengage Learning
Prelude to Programming
Prelude to Programming
Computer Engineering
ISBN:
9780133750423
Author:
VENIT, Stewart
Publisher:
Pearson Education
Sc Business Data Communications and Networking, T…
Sc Business Data Communications and Networking, T…
Computer Engineering
ISBN:
9781119368830
Author:
FITZGERALD
Publisher:
WILEY