ACM PKU 3067 Japan
摘要:
树状数组的题,很简单,只是我做了一下午,哈哈!都是因为好久没有写代码了,这是个多组测试数据的题,初始化得注意点;树状数组的思想很简单,先排序,然后找交叉点,交叉点的数目等于A数组相对于x位置右边的sum值。#include <iostream>#include <algorithm>#include <cstring>#include <stdio.h>using namespace std;struct node { int e,w;} tmp[1000010];long long A[1005];int MAX_N;bool operator 阅读全文
posted @ 2012-03-24 16:59 _Clarence 阅读(117) 评论(0) 推荐(0) 编辑