杭电acm2060
#include <stdio.h> int main() { int n, cScore, oScore, m, ans, i,d[6]={2, 3, 4, 5, 6, 7}; scanf("%d", &n); while(n--) { ans = 0; scanf("%d%d%d", &m, &cScore, &oScore); if(m==6) { ans = 27; } if(m>6) { ans = 27 + 8 * (m - 6); } if(m<6) { for(i=5; i>=6-m; i--) ans += d[i]; } ans += cScore; if(ans>=oScore) printf("Yes\n"); else printf("No\n"); } return 0; }