#include <iostream>
#include <string>
#include <cstdio>
#include <string.h>
#include <ctype.h>
using namespace std;
string str;
void input()
{
while (getline(cin, str))
{
if (str[0] == '|')
{
int ans = 0;
for (int i = 1; i < str.length() - 1; i++)
{
if (str[i] == '.')
{
continue;
}
if (str[i] == 'o')
{
ans = ans * 2 + 1;
}
else
{
ans = ans * 2;
}
}
cout << (char)ans;
}
}
}
int main()
{
input();
return 0;
}
ACM->uva10878
最新推荐文章于 2018-08-20 23:57:18 发布