How many residents#10025

How many residents

1 second
64 megabytes
Easy

On a certain island, the inhabitants are remarkably consistent in their habits, particularly in their choice of clothing color. Once they select a color in childhood, they wear clothes of that color exclusively for the rest of their lives.

A reputable agency conducted a survey among the island residents who use a social network. The survey consisted of a single question: how many other island residents, apart from yourself, have chosen the same clothing color as you? Each participant provided a truthful answer, indicating the number of other residents who wear clothes of the same color.

Based on the survey results, determine the minimum possible number of residents on this island.

The total number of responses (survey answers) does not exceed 10^6, and each response is within the range .

Input

The input consists of a single line containing a non-zero number of non-negative integers, each not exceeding . These integers represent the responses of the islanders to the survey question.

Output

Output a single line containing the minimum possible number of residents on the island.

Examples

Example 1

Loading
Loading

Example 2

Loading
Loading

Note

If two residents provide the same answer, they might be wearing clothes of the same color. Given no other responses, it is possible that no other residents wear a different color. Thus, the total number of island residents could be as few as , as we are seeking the minimum possible number of residents.