import java.util.Scanner; public class Test { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int s = 0, cnt = 0; s += sc.nextInt()*100; s += sc.nextInt()*25; s += sc.nextInt(); s %= 1000; cnt += s/100; s %= 100; cnt += s/25 + s%25; System.out.println(cnt); } }