#include int main() { using namespace std; int L, M, N; cin >> L >> M >> N; int total = L * 100 + M * 25 + N; int after = total / 1000; total %= 1000; after += total / 100; total %= 100; after += total / 25; total %= 25; after += total; cout << after << endl; return 0; }