#include int main(void){ int L, M, N; scanf("%d\n%d\n%d\n", &L, &M, &N); M += L / 25; L %= 25; N += M / 4; M %= 4; N %= 10; printf("%d\n", L+M+N); return 0; }