hdu 5774 Where Amazing Happens

没有直接人肉,选择打表了。

#include<iostream>
#include<cstdio>
#include<queue>
#include<cstring>
using namespace std;

int main(){
    int n,t=1;
    char a[33];
    scanf("%d",&n);getchar();
    while(n--){
        int ans;
        gets(a);
        //puts(a);
        if(!strcmp(a,"Cleveland Cavaliers")) ans=1;
        else if(!strcmp(a,"Golden State Warriors"))  ans=2;
        else if(!strcmp(a,"San Antonio Spurs"))  ans=5;
        else if(!strcmp(a,"Miami Heat"))  ans=3;
        else if(!strcmp(a,"Dallas Mavericks")) ans=1;
        else if(!strcmp(a,"L.A. Lakers"))  ans=11;
        else if(!strcmp(a,"Boston Celtics"))ans=17;
        else if(!strcmp(a,"Detroit Pistons"))ans=3;
        else if(!strcmp(a,"Chicago Bulls"))ans=6;
        else if(!strcmp(a,"Houston Rockets"))ans=2;
        else if(!strcmp(a,"Philadelphia 76ers"))ans=2;
        else if(!strcmp(a,"Seattle Sonics"))ans=1;
        else if(!strcmp(a,"Washington Bullets"))ans=1;
        else if(!strcmp(a,"Portland Trail Blazers"))ans=1;
        else if(!strcmp(a,"New York Knicks"))ans=2;
        else if(!strcmp(a,"Milwaukee Bucks"))ans=1;
        else if(!strcmp(a,"St. Louis Hawks"))ans=1;
        else if(!strcmp(a,"Syracuse Nats"))ans=1;
        else if(!strcmp(a,"Minneapolis Lakers"))ans=5;
        else if(!strcmp(a,"Rochester Royals"))ans=1;
        else if(!strcmp(a,"Baltimore Bullets"))ans=1;
        else if(!strcmp(a,"Philadelphia Warriors")) ans=2;
        else  ans=0;
        printf("Case #%d: %d\n",t++,ans);
    }
   return 0;
}


评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值