// #define TASK "sweets"
// #pragma GCC optimize("Ofast")
// #pragma GCC target("sse4.2,avx2")
// #pragma GCC optimize("unroll-loops")
// #pragma GCC optimize("unroll-all-loops")
#include <bits/stdc++.h>
// #include <ext/rope>
// #include <ext/pb_ds/assoc_container.hpp>
// #include <ext/pb_ds/detail/standard_policies.hpp>
// using namespace __gnu_cxx;`
// using namespace __gnu_pbds;
using namespace std;
// template<class K>
// using ordered_set = tree<K, null_type, less<K>, rb_tree_tag, tree_order_statistics_node_update>;
// template<class K, class T>
// using ordered_map = tree<K, T, less<K>, rb_tree_tag, tree_order_statistics_node_update>;
// mt19937 rnd((int)chrono::high_resolution_clock::now().time_since_epoch().count());
#define all(x) x.begin(), x.end()
#define rall(x) x.rbegin(), x.rend()
#define F first
#define S second
#define pb push_back
#define pii pair<int, int>
#define len(x) (long long)x.size()
#define int long long
typedef long long ll;
typedef long double ld;
const long long INF = (int)numeric_limits<int>::max() >> 1;
const long long MAXN = (long long)1e5 + 10;
const long long MOD = (long long)1e9 + 7;
const long double EPS = (long double)1e-12;
// char _buf_[(int)6e6];
// size_t _p_ = 0;
// inline void *operator new(size_t _n_) {
// _p_ += _n_;
// return _buf_ + _p_ - _n_;
// }
// inline void operator delete(void*) {};
ll power(ll x, ll n, ll mod = 1e9 + 7) {
if (n == 0) return 1ll;
if (n & 1ll) return power(x, n - 1ll, mod) * x % mod;
ll tmp = power(x, n >> 1ll, mod);
return (tmp * tmp) % mod;
}
ll gcd(ll a, ll b) {
if (b == 0) return a;
return gcd (b, a % b);
}
ll lcm(ll a, ll b) {
return a / gcd(a, b) * b;
}
template<typename A, typename B>
bool cmax(A &a, const B &b) {
if (a < b) {
a = b;
return true;
}
return false;
}
template<typename A, typename B>
bool cmin(A &a, const B &b) {
if (a > b) {
a = b;
return true;
}
return false;
}
signed main() {
#ifndef LOCAL
#ifdef TASK
freopen(TASK".in", "r", stdin);
freopen(TASK".out", "w", stdout);
#endif
#endif
iostream::sync_with_stdio(0);
cin.tie(0);
cout.tie(0);
// == SOLUTION == //
int n;
cin >> n;
vector<int> a;
for (int i = 0; i < n; i++) {
int l, r;
cin >> l >> r;
assert(l == r);
a.pb(l);
}
cout << power(2, n) << "\n";
}
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Incorrect |
2 ms |
384 KB |
Output isn't correct |
2 |
Halted |
0 ms |
0 KB |
- |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Incorrect |
2 ms |
384 KB |
Output isn't correct |
2 |
Halted |
0 ms |
0 KB |
- |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Runtime error |
3 ms |
640 KB |
Execution killed with signal 11 (could be triggered by violating memory limits) |
2 |
Halted |
0 ms |
0 KB |
- |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Incorrect |
2 ms |
384 KB |
Output isn't correct |
2 |
Halted |
0 ms |
0 KB |
- |