CSU 1639 队长,我想进集训队!

水题

#include<cstdio>

int main()

{



    int x1, x2, x3, u, h;

    int n;

    while (~scanf("%d", &n))

    {

        while (n--)

        {

            char s[5];

            scanf("%s", s);

            scanf("%d%d%d%d%d", &x1, &x2, &x3, &u, &h);

            int fen = x1 + 2 * x2 + 5 * x3 + u + h;

            //printf("%d\n", x1 + 2 * x2 + 5 * x3 + u + h);

            if ((s[0] == 'm'&&fen >= 90) || (s[0] == 'f'&&fen >= 60))

                printf("Welcome\n");

            else

            {

                if (s[0] == 'm') printf("%d\n", 90 - fen);

                else printf("%d\n", 60 - fen);

            }

        }

    }

    return 0;

}

 

你可能感兴趣的:(su)