SP33999 ADAFEAR - Ada and Primal Fear
Description
As you might already know, Ada the Ladybug is a farmer. She grows many vegetables. During past months, her crop was attacked by colony of parasites. Each vegetable was attacked by **A $ _{i} $** parasites. Ada has only limited answer for this. She bought a few bottles with **Primal Fear**, which is a mixture agains parasites.
**Primal Fear** works in following way: Each **Primal Fear** bottle has a power assigned to it (which is coincidentally a prime number). If it is applied to a vegetable with **N** parasites on it, either the **N** is divisible by its **power**, then the size of colony is reduced to **N/power**, or - if the size is not divisible - then it has no effect. Also, as soon as you apply mixture against a colony, the rest of colony will become immune agains **Primal Fear**.
Ada didn't know what to buy so she bought one bottle of every possible **power**. Can you find out the best strategy to fight agains parasites?
Input Format
The first line of input will contain **1 , the number of vegetable.**
The line will contain **N** numbers **1 , the size of colony on **i $ ^{th} $** vegetable.**
Output Format
Print the minimum sum of sizes of colonies which could be achieved after applying **Primal Fear** optimally.