#include<iostream> using namespace std; int main() { int n; cin >> n; int t = n / 50; int sum = t * 7; n %= 50; t = n / 30; sum += t * 4; n %= 30; t = n / 10; sum += t; cout << sum << endl;; return 0; }