vj1454 牛的RP

vj1454 牛的RP - / / / 'r' or...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
//±ÉÈ˵ķ½·¨ //Ä£Äâ //×¢Òâµ¹×Åͳ¼Æ¼´¿É ²»ÒªÔÚÔÃû×ÖÉÏɾµô 'r' or 'p' ÕâÑù¿ÉÄܵ¼Ö±»ËûÃǼä¸ôµÄ×Öĸ ¡®c' 'o' 'w' Á¬ÔÚÒ»Æð¶àͳ¼ÆÁË //ͬÑùÈç¹ûÏÈɾ 'cow' ËûÁ½±ßµÄ 'r' ºÍ 'p' Ò²»áÁ¬ÆðÀ´ / const stand='reioxzsj'; var n,rp,maxr,len:integer; rpcow,cname:ansistring; procedure main; var i,j,l:integer; begin readln(n); for i:=1 to n do begin readln(cname); if pos(stand,cname)=0 then continue; rp:=0; l:=length(cname); if (cname[l]='r') or (cname[l]='p') then inc(rp,5);
Background image of page 1
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.

Ask a homework question - tutors are online