vj1037 搭建双塔

Vj1037 搭建双塔

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

View Full Document Right Arrow Icon
//±ÉÈ˵ķ½·¨ //dp //¿¼ÂÇÈý´Î·½µÄËã·¨ //Éè f[ i , j ] Ϊǰ i ¸öË®¾§¹¹³ÉÒ»¸ö¸ßΪ i Ò»¸ö¸ßΪ j µÄ¿ÉÄÜÇé¿ö Ôò¶ÔÓÚµ±Ç °Ë®¾§ ¿ÉÒÔÑ¡Ôñ·Åµ½ÆäÖÐÒ»¸öËþÉÏ //ÆäʵֻҪ֪µÀÁ½ËþµÄ×î´óËþ¸ß ÓÖÖªµÀËüÃÇµÄ²î ¼ÈÓкÍÉÏÊöÒ»ÑùµÄЧ¹û //Éè f[ i , j ] Ϊǰ i ¸öË®¾§¹¹³É²îΪ j ʱ¸ßËþµÄ¸ß¶È //×¢Òâ·ÖÈýÖÖÇé¿ö //1.µÚ i ¸öË®¾§·ÅÈë¸ßËþÉÏ //2.µÚ i ¸öË®¾§·Åµ½°«ËþÉÏ //3.µÚ i ¸öË®¾§·Åµ½°«ËþÉÏ Ê¹°«Ëþ±ä¸ßËþ ·ÅÉϺóÔÀ´µÄ¸ßËþ±È°«Ëþ¸ß -j ¼´·ÅÇ°¸ß±È °«¶à h[i]-j ÏÖÔÚ°«±È¸ß¶à j ° const maxn=100; maxh=2000; var n,sum:integer; h:array[0. .maxn] of integer; f:array[boolean,0. .maxh] of integer;
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

Vj1037 搭建双塔

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