Hide

Problem C
Coin Counter

Given an image of a set of Swedish coins valued 1, 5 and 10 SEK, what is their sum?

The coins look like this:

\includegraphics[width=0.2\textwidth ]{1.png}
Figure 1: 1 SEK coin
\includegraphics[width=0.2\textwidth ]{5.png}
Figure 2: 5 SEK coin
\includegraphics[width=0.2\textwidth ]{10.png}
Figure 3: 10 SEK coin

Input

The input is a JPEG-formatted image with dimensions $1000 \times 1000$.

No coin will be covered by other coins such that the visible parts of it is divided into two.

See the downloadable file sampleimages.zip in the menu to the right to download some example inputs and outputs.

Output

Output a single number; the sum of all the coins in the input image.

Scoring

Your solution will be tested on a set of test groups, each worth a number of points. To get the points for a test group you need to solve all test cases in the test group. Your final score will be the maximum score of a single submission.

Group

Points

Constraints

1

20

There are only 1 SEK coins. None of the coins are rotated or cover each other.

2

30

There are only 1 SEK coins. None of the coins cover each other.

3

75

There are only 1 SEK coins.

4

60

None of the coins are rotated or cover each other.

5

90

None of the coins cover each other.

6

225

No further restrictions.

Please log in to submit a solution to this problem

Log in