In the practicals of the programming courses at the Vrije Universiteit all handed in assignments are stored digitally in a database. To make sure that students write their own code, these assignments are checked against each other by a plagiarism checker. The plagiarism checker creates a file per student. The first line of such a file contains the student number of said student, and the rest of the lines of this file each contains:
A line "number1 xx% number2" means that the student with student number number1 has an xx% match with the student with number2. This does not automatically imply that the student with number2 also has an xx% match with the student with student number number1!
Write a program that:
reads the student number on the first line of the file
creates a bar chart of the matches of the student with that student number for the ten intervals 1-10, 11-20, ..., 91-100 (a line represents a match of that student if his or her number appears in the spot of number1)
prints the number of expected copies of that student (a match is an expected copy if the match percentage is > 59%)
The bar chart can be represented by = characters.
In case of the example file shown above, the bar chart would have one bar in the second interval (as 15 is in the interval 11-20), and the program would print that there are 0 expected copies.
It is not our intention to break the school's academic policy. Posted solutions are meant to be used as a reference
and should not be submitted as is. We are not held liable for any misuse of the solutions.
Please see the frequently asked questions page
for further questions and inquiries.
Kindly complete the form.
Please provide a valid email address and we will get back to you within 24 hours.
Payment is through PayPal, Buy me a Coffee
or Cryptocurrency.
We are a nonprofit organization however we need funds to keep this organization operating
and to be able to complete our research and development projects.