水题,枚举即可. 第一次提交WA,没有注意这道题并不是Special Judge,如果有多组顺序符合要求,需要输出字典序最靠前的一组. 虽然用了string,不过代码写的还是很垃圾. /* UVa 102; Ecological Bin Packing - sqybi's code */ //for my winsty #include #include using namespace std; const int nn = 3; int t, res, now; int a[nn][nn]; bool u[nn]; char ch[nn] = {'B', 'G', … Continue reading
2008年08月22日
by sqybi
0 comments