Skip to content

Latest commit

 

History

History
25 lines (17 loc) · 613 Bytes

README.md

File metadata and controls

25 lines (17 loc) · 613 Bytes

Lazy Professor

I am the laziest professor ever. I've given a multiple choice test (A-D are valid answers) but I lost my test key. I'll assume that whatever answer was most popular for a question is the correct answer.

I've included a file that contains the students quiz answers. Each row represents one student. Write code that figures out the most popular answer to each question and then prints out the key.

Example:

Given:

ABCCADCB
DDDCAACB
ABDDABCB
AADCAACC
BBDDAACB
ABDCCABB
ABDDCACB

Output:

ABDCAACB

test.txt