#include using namespace std; struct cww{cww(){ios::sync_with_stdio(false);cin.tie(0);}}star; int main() { int L, M, N; cin >> L >> M >> N; int total = ( L*100 + M*25 + N ) % 1000, count{}; while( total != 0 ) { if( total >= 1000 ) { total -= 1000; } else if( total >= 100 ) { count++; total -= 100; } else if( total >= 25 ) { count++; total -= 25; } else if( total >= 1 ) { count++; total -= 1; } } cout << count << endl; return 0; }