DawnLannister @ 2017-09-20 22:48:36
var bi:array[1..20]of string=
('one','two','three','four','five','six','seven','eight','nine','ten','eleven','twelve','thirteen','fourteen','fifteen','sixt
een','seventeen','eighteen','nineteen','twenty');
i,j,k:longint;
s,key:string;
function num(x:string):string;
var i:longint;f:string;c:boolean;
begin c:=false;
for i:=1 to 20 do if bi[i]=x then begin c:=true;break;end;
if c then begin str(sqr(i),f);
exit(copy('0'+f,length(f),2))end else exit('');
end;
function find(x:string):longint;
var i:longint;
begin
i:=1;
while (x[i]<>' ')and(x[i]<>'.') do inc(i);exit(i);
end;
begin
readln(s);key:='';
for i:=1 to length(s) do if s[i] in ['A'..'Z'] then s[i]:=chr(ord(s[i])+32);
j:=find(s);
while s<>'' do
begin
key:=concat(key,num(copy(s,1,j-1)));
delete(s,1,j);
j:=find(s);
end;
j:=1;k:=length(key);
while (key[j]='0')and(j<k) do inc(j);
for i:=j to k do write(key[i]);
end.
by pangpengzhu @ 2017-09-21 07:43:20
不要用自动识别语言试试
by WhisperingStars @ 2018-02-12 20:07:08
你是没见过C++硬是读成了Python