摘要:
1. 数字三角形,POJ1163,不多说。code:#include<cstdio>#include<iostream>#include<cstring>#include<fstream>#include<cstdlib>#include<memory>#include<algorithm>#definereadfreopen("numtri.in","r",stdin)#definewritefreopen("numtri.out","w&
阅读全文
posted @ 2012-05-23 17:45
追逐.
阅读(165)
推荐(0)
编辑
摘要:
1. 恶心的题..考虑了很久没好的想法,看了下报告,直接按图处理即可!搞毛啊,为什么能保证图示能包含所有情况??枚举每个矩形位置和放置情况时用了next_permutation(),next_permutation()是生成下一字典序最小的排列,不包含当前排列,所以一般用do..while()语句。code:#include<cstdio>#include<iostream>#include<cstring>#include<fstream>#include<cstdlib>#include<memory>#include
阅读全文
posted @ 2012-05-23 17:33
追逐.
阅读(164)
推荐(0)
编辑