2018/12/12 acm日常 第二周 第六题
HDU-2055
问题链接

// A code block
#include<iostream>
using namespace std;
int main()
{
int n = 0;
cin >> n;
for (int i = 0,x=0; i < n; i++)
{
char word; int num;
cin >> word >> num;
if ((int)word < 91)
{
x = (int)word - 64;
x += num;
cout << x << endl;
}
else
{
x = 96 - (int)word;
x += num;
cout << x << endl;
}
}
return 0;
}

以上为临时版本。

浙公网安备 33010602011771号