#include int main() { int L, M, N; // 100, 25, 1 std::cin >> L >> M >> N; while (N >= 25) { N -= 25; M += 1; } while (M >= 4) { M -= 4; L += 1; } while (L >= 10) { L -= 10; } std::cout << (L + M + N) << std::endl; return 0; }