import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int a = sc.nextInt();// 100 int b = sc.nextInt();// 25 int c = sc.nextInt();// 1 b += c / 25; int sum = b / 4; a += sum; b -= sum * 4; sum = a / 10; a -= sum * 10; System.out.println(a + b + c); } }