I hereby claim:
- I am crackersamdjam on github.
- I am crackersamdjam (https://keybase.io/crackersamdjam) on keybase.
- I have a public key ASDAoBJ6yIs_JyfdM27PQYidjJ0G6hFOwJeUwa5M5FxUTwo
To claim this, I am signing this object:
#include <bits/stdc++.h> | |
#define all(x) (x).begin(), (x).end() | |
using namespace std; | |
using ll = long long; | |
constexpr ll mod = 1e9+9; | |
template<class T, class U> T fpow(T _base, U _pow, T _mod){_base %= _mod; T _x = 1; for(; _pow > 0; _pow >>= 1){ if(_pow&1) _x = _x*_base%_mod; _base = _base*_base%_mod;} return _x;} | |
template<class T> T divmod(T _a, T _b, T _mod){return _a*fpow(_b, _mod-2, _mod)%_mod;} |
#include <bits/stdc++.h> | |
#define all(x) (x).begin(), (x).end() | |
#ifdef LOCAL | |
template<typename T> void pr(T a){std::cerr<<a<<std::endl;} | |
template<typename T, typename... Args> void pr(T a, Args... args){std::cerr<<a<<' ',pr(args...);} | |
#else | |
template<typename... Args> void pr(Args... args){} | |
#endif |
I hereby claim:
To claim this, I am signing this object:
#pragma GCC optimize("O3") | |
#pragma GCC target("sse4") | |
#include <bits/stdc++.h> | |
#define all(x) (x).begin(), (x).end() | |
#define gc getchar_unlocked() | |
#define pc(x) putchar_unlocked(x) | |
template<typename T> void scan(T &x){x = 0;bool _=0;T c=gc;_=c==45;c=_?gc:c;while(c<48||c>57)c=gc;for(;c<48||c>57;c=gc);for(;c>47&&c<58;c=gc)x=(x<<3)+(x<<1)+(c&15);x=_?-x:x;} | |
template<typename T> void printn(T n){bool _=0;_=n<0;n=_?-n:n;char snum[65];int i=0;do{snum[i++]=n%10+48;n/= 10;}while(n);--i;if (_)pc(45);while(i>=0)pc(snum[i--]);} | |
template<typename First, typename ... Ints> void scan(First &arg, Ints&... rest){scan(arg);scan(rest...);} |
#include <bits/stdc++.h> | |
#define gc getchar_unlocked() | |
#define pc(x) putchar_unlocked(x) | |
template<typename T> void scan(T &x){x = 0;register bool _=0;register T c=gc;_=c==45;c=_?gc:c;while(c<48||c>57)c=gc;for(;c<48||c>57;c=gc);for(;c>47&&c<58;c=gc)x=(x<<3)+(x<<1)+(c&15);x=_?-x:x;} | |
template<typename T> void printn(T n){register bool _=0;_=n<0;n=_?-n:n;char snum[65];int i=0;do{snum[i++]=n%10+48;n/= 10;}while(n);--i;if (_)pc(45);while(i>=0)pc(snum[i--]);} | |
template<typename First, typename ... Ints> void scan(First &arg, Ints&... rest){scan(arg);scan(rest...);} | |
template<typename T> void print(T n){printn(n);pc(10);} | |
template<typename First, typename ... Ints> void print(First arg, Ints... rest){printn(arg);pc(32);print(rest...);} | |
using namespace std; |
import java.util.*; | |
public class test{ | |
public static void main(String[] args){ | |
Scanner in = new Scanner(System.in); | |
int n = in.nextInt(), m = in.nextInt(); | |
int[] dis = new int[n+1]; | |
ArrayList<Edge>[] adj = new ArrayList[n+1]; | |
for(int i = 0; i <= n; i++){ | |
dis[i] = Integer.MAX_VALUE; |
#pragma GCC optimize("O3") | |
#pragma GCC optimize("unroll-loops") | |
#pragma GCC target("sse4,popcnt,abm,mmx,tune=native") | |
#include <bits/stdc++.h> | |
#define gc getchar_unlocked() | |
#define pc(x) putchar_unlocked(x) | |
template<typename T> void scan(T &x){x = 0;bool _=0;T c=gc;_=c==45;c=_?gc:c;while(c<48||c>57)c=gc;for(;c<48||c>57;c=gc);for(;c>47&&c<58;c=gc)x=(x<<3)+(x<<1)+(c&15);x=_?-x:x;} | |
template<typename T> void printn(T n){bool _=0;_=n<0;n=_?-n:n;char snum[65];int i=0;do{snum[i++]=n%10+48;n/= 10;}while(n);--i;if (_)pc(45);while(i>=0)pc(snum[i--]);} | |
template<typename First, typename ... Ints> void scan(First &arg, Ints&... rest){scan(arg);scan(rest...);} |
#include <bits/stdc++.h> | |
#define gc getchar_unlocked() | |
#define pc(x) putchar_unlocked(x) | |
template<typename T> void scan(T &x){x = 0;register bool _=0;register T c=gc;_=c==45;c=_?gc:c;while(c<48||c>57)c=gc;for(;c<48||c>57;c=gc);for(;c>47&&c<58;c=gc)x=(x<<3)+(x<<1)+(c&15);x=_?-x:x;} | |
template<typename T> void printn(T n){register bool _=0;_=n<0;n=_?-n:n;char snum[65];int i=0;do{snum[i++]=n%10+48;n/= 10;}while(n);--i;if (_)pc(45);while(i>=0)pc(snum[i--]);} | |
template<typename First, typename ... Ints> void scan(First &arg, Ints&... rest){scan(arg);scan(rest...);} | |
template<typename T> void print(T n){printn(n);pc(10);} | |
template<typename First, typename ... Ints> void print(First arg, Ints... rest){printn(arg);pc(32);print(rest...);} | |
using namespace std; |
#include <bits/stdc++.h> | |
#define gc getchar_unlocked() | |
#define pc(x) putchar_unlocked(x) | |
template<typename T> void scan(T &x){x = 0;register bool _=0;register T c=gc;_=c==45;c=_?gc:c;while(c<48||c>57)c=gc;for(;c<48||c>57;c=gc);for(;c>47&&c<58;c=gc)x=(x<<3)+(x<<1)+(c&15);x=_?-x:x;} | |
template<typename T> void print(T n){register bool _=0;_=n<0;n=_?-n:n;char snum[65];int i=0;do{snum[i++]=n%10+48;n/= 10;}while(n);--i;if (_)pc(45);while(i>=0)pc(snum[i--]);pc(10);} | |
template<typename First, typename ... Ints> | |
void scan(First &arg, Ints&... rest){scan(arg);scan(rest...);} | |
using namespace std; | |
typedef long long ll; |
#include <bits/stdc++.h> | |
#define gc getchar_unlocked() | |
#define pc(x) putchar_unlocked(x) | |
template<typename T> void scan(T &x){x = 0;register bool _=0;register T c=gc;_=c==45;c=_?gc:c;while(c<48||c>57)c=gc;for(;c<48||c>57;c=gc);for(;c>47&&c<58;c=gc)x=(x<<3)+(x<<1)+(c&15);x=_?-x:x;} | |
template<typename T> void print(T n){register bool _=0;_=n<0;n=_?-n:n;char snum[65];int i=0;do{snum[i++]=n%10+48;n/= 10;}while(n);--i;if (_)pc(45);while(i>=0)pc(snum[i--]);pc(10);} | |
template<typename First, typename ... Ints> | |
void scan(First &arg, Ints&... rest){scan(arg);scan(rest...);} | |
using namespace std; |