ACM: 线段树 poj 2352
来源:互联网 发布:mac安装jdk 编辑:程序博客网 时间:2024/06/05 05:08
Description
You are to write a program that will count the amounts of the starsof each level on a given map.
Input
Output
Sample Input
5
1 1
5 1
7 1
3 3
5 5
Sample Output
1
2
1
1
0
题意: 计算每种等级的星星的个数, 每个星星的等级是它坐标左下方的星星个数.
解题思路:
代码:
#include <cstdio>
#include <iostream>
#include <cstring>
using namespace std;
#define MAX 32005
struct node
{
}pt[MAX*3];
int n;
int result[MAX/2];
int x, y;
void build_tree(int l, int r, int pos)
{
}
int find(int l, int r, int pos)
{
}
void add(int x, int pos)
{
}
int main()
{
//
}
- ACM: 线段树 poj 2352
- ACM: 线段树 poj 1177
- ACM: 线段树 poj 3468
- ACM: 线段树 poj 3277
- ACM: 线段树 poj 3264
- ACM: 线段树 poj 3368
- ACM: 线段树 poj 2528 离散化即可
- ACM: 线段树 poj 1151 足足想了三…
- ACM: 线段树 poj 2828 认真对待每…
- ACM: 线段树 poj 2777 继续熟练线…
- ACM: 线段树 poj 2886 约瑟夫问题
- ACM: 线段树 poj 2750 连续最大和
- ACM: 线段树 poj 2482 煽情的情书!…
- poj 2352 Stars 线段树
- poj 3321 Apple Tree 线段树
- poj 2182 Lost Cows 线段树
- 【线段树】 POJ 2828 Buy Tickets
- POj 2379 ACM Rank Table
- ACM: 动态规划题 poj 1036 问题简…
- ACM: 划分树 poj 2104
- ACM: 划分树 poj 2761 在poj2104基…
- ACM: 最小堆 poj 2227 最小堆 fro…
- ACM: 最小堆 poj 2274 思路清晰, …
- ACM: 线段树 poj 2352
- ACM: 线段树 poj 1151 足足想了三…
- 运算符与表达式
- ACM: 线段树 poj 1177
- 计算机和资料 转载
- ACM: trie树 poj 2513
- ACM: 线段树 poj 2528 离散化即可
- ACM: 线段树 poj 2828 认真对待每…
- ACM: 线段树 poj 2777 继续熟练线…