update
This commit is contained in:
parent
aa21e80017
commit
3e55ed0516
@ -1,14 +1,28 @@
|
||||
#include <cstdint>
|
||||
#include <iostream>
|
||||
#include <limits>
|
||||
#include <sys/types.h>
|
||||
|
||||
using ll = int64_t;
|
||||
using ull = uint64_t;
|
||||
|
||||
volatile const ll n{};
|
||||
constexpr ull ullmax=std::numeric_limits<ull>::max();
|
||||
ull n;
|
||||
|
||||
int main(){
|
||||
// std::cin>>*(ll *)(void*)&n;
|
||||
std::cout<<*(ll *)(void*)&n<<'\n';
|
||||
for(ll i=1;i<=n;i++){
|
||||
|
||||
std::cin>>n;
|
||||
ull ans=0;
|
||||
for(ull i=1;i<=n;i++){
|
||||
static ull x,y;
|
||||
std::cin>>x>>y;
|
||||
static std::hash<ull> hash;
|
||||
static ull *arr =[]()->ull*{
|
||||
ull *a = new ull(ullmax+1);
|
||||
for(ull i=0;i<ullmax;i++){
|
||||
a[i]=0;
|
||||
}
|
||||
return a;
|
||||
}();
|
||||
ans=ans+i*arr[hash(x)]%ullmax;
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user