SP1794 DRAGON2 - Greedy Hydra II

Description

The problem description is the same as the problem [DRAGON](http://www.spoj.com/problems/DRAGON).

Input Format

The first line contains 3 integers N(1

Output Format

Output one line contains a single integer denoted the minimum weight of illness of the hydra. If we can't divide the fruit into M groups, output "-1"(without quotes).