B - Linear Algebra Test————只给思路

B - Linear Algebra Test————只给思路

https://cn.vjudge.net/contest/285982#problem/B
因为值的范围是1e9;
所以不可能a[1e9] 这么大的数组(占内存)

因为需要多次查找
创建一个普通的结构体
struct{
int a;
int b;
}
这种方法车罩很麻烦 时间复杂度O(n*n);

所以可以用C++ 的map容器(c++中map 是通过AVL实现的, map 是一种映射)。

posted @ 2019-03-14 11:39 Monkey1 阅读( ...) 评论( ...) 编辑 收藏

猜你喜欢

转载自blog.csdn.net/qq_43824791/article/details/88792893