vj1304 回文

vj1304 回文 - / / /+ const maxn=100;

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
//±ÉÈ˵ķ½·¨ //¸ß½øÖƼӷ¨+ÅжϻØÎÄ / const maxn=100; stand='0123456789ABCDEF'; var n,step,len:integer; a,b:array[0. .maxn] of integer; procedure out; begin writeln('Impossible!'); halt; end; function check:boolean; var i:integer; begin for i:=1 to len do if a[i]<>a[len-i+1] then exit(false); exit(true); end; procedure init; var i:integer; s:string; begin readln(n); readln(s); len:=length(s); for i:=1 to len do a[i]:=pos(s[i],stand)-1;
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Background image of page 2
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 02/21/2011 for the course CS 001 taught by Professor 001 during the Spring '11 term at Shandong University.

Page1 / 2

vj1304 回文 - / / /+ const maxn=100;

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online