#include using namespace std; int main () { ios_base::sync_with_stdio(false); cin.tie(NULL); int tt; cin >> tt; while(tt--){ int x, y , z; cin >> x >> y >> z; cout << (x * 5 + y * 10) / z << endl; } }