|  | 
      
        |  数字金字塔 |  
        | var i,n,k,j:integer; begin
 read(n);
 for i:=n downto 1 do
 begin
 write('':n-0-i);k:=0;
 for j:=1 to 2*i-1 do
 begin
 if k<=i then
 k:=k+1;
 else
 k:=k-1;
 write(i);
 end;
 writeln;
 end;
 end.
 
 ( 2015/4/18 9:03:17 )
 |  
 
          
          
            |  123 |  
            | var i,j,k:string; a,s,d:integer;
 begin
 assign(input,'p1651.in');
 assign(output,'p1651.out');
 reset(input);
 rewrite(output);
 readln(a);
 for s:=1 to a do
 begin
 readln(i);
 j:=copy(i,1,1);
 d:=d+1;
 if (j='A')or(j='B')or(j='C')or(j='D')or(j='E')or(j='F')or(j='G')or(j='R')or(j='S')or(j='T') then
 d:=d-1;
 end;
 write(d);
 close(input);
 close(output);
 end.
 (  )
 |  
            |  123 |  
            | var a:array[1..3] of char; i,j:integer;
 t:char;
 begin
 assign(input,'p1614.in');
 assign(output,'p1614.out');
 reset(input);
 rewrite(output);
 
 for i:=1 to 3 do read(a[i]);
 for i:=1 to 2 do
 for j:=1 to 3-i do
 if a[j]<a[j+1] then
 begin
 t:=a[j];
 a[j]:=a[j+1];
 a[j+1]:=t;
 end;
 for i:=1 to 3 do
 write(a[i]);
 writeln;
 close(input);
 close(output);
 end.
 
 (  )
 |  
            |  1 |  
            | var a:array[1..100,1..100]of integer; i,j,n,k:integer;
 begin
 assign(input,'p1047.in');
 assign(output,'p1047.out');
 reset(input);
 rewrite(output);
 
 fillchar(a,sizeof(a),0);
 read(n);
 for j:=1 to n do
 begin
 for i:=j to n do
 begin
 k:=k+1;
 a[i,j]:=k;
 end;
 end;
 for i:=1 to n do
 begin
 for j:=1 to n do
 if a[i,j]=0 then
 write('':3)
 else
 write(a[i,j]:3);
 writeln;
 end;
 close(input);
 close(output);
 
 end.
 (  )
 |  |