首页 > 学院 > 开发设计 > 正文

斯诺登的密码

2019-11-08 02:32:44
字体:
来源:转载
供稿:网友
var a:array[1..6]of string; s,ss,t:string; x:char; n,i,j,b:longint;begin while x<>'.' do begin  read(x);  s:=s+x; end; for i:=1 to 6 do begin  b:=pos(' ',s);  ss:=copy(s,1,b-1);  if (ss='zero')then a[i]:='00';  if (ss='one')or(ss='a')or(ss='another')or(ss='first') then a[i]:='01';  if (ss='two')or(ss='both')or(ss='second') then a[i]:='04';  if (ss='three')or(ss='third') then a[i]:='09';  if (ss='four') then a[i]:='16';  if ss='five' then a[i]:='25';  if ss='six' then a[i]:='36';  if ss='seven' then a[i]:='49';  if ss='eight' then a[i]:='64';  if ss='nine' then a[i]:='81';  if ss='ten' then a[i]:='00';  if ss='eleven' then a[i]:='21';  if ss='twelve' then a[i]:='44';  if ss='thirteen' then a[i]:='69';  if ss='fourteen' then a[i]:='96';  if ss='fifteen' then a[i]:='65';  if ss='sixteen' then a[i]:='56';  if ss='seventeen' then a[i]:='89';  if ss='eighteen' then a[i]:='24';  if ss='nineteen' then a[i]:='61';  if ss='twenty' then a[i]:='00';  delete(s,1,b); end; for i:=1 to 5 do  for j:=i+1 to 6 do if a[i]>a[j] then begin  t:=a[i];  a[i]:=a[j];  a[j]:=t; end; s:=''; for i:=1 to 6 do  s:=s+a[i]; i:=1; if s='' then write(0); while (s[i]='0')and(i<length(s)) do inc(i); for j:=i to length(s) do write(s[j]);end.
发表评论 共有条评论
用户名: 密码:
验证码: 匿名发表