QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#475189#9120. Huge Segment Treeucup-team008#AC ✓79ms61888kbC++2314.3kb2024-07-13 13:00:332024-07-13 13:00:34

Judging History

你现在查看的是最新测评结果

  • [2024-07-13 13:00:34]
  • 评测
  • 测评结果:AC
  • 用时:79ms
  • 内存:61888kb
  • [2024-07-13 13:00:33]
  • 提交

answer

// {{{ y0105w49 template 24K21
// hi mom
#ifndef NULL
#ifdef __GNUC__
#ifndef __clang__
// #include <bits/stdc++.h>
#include <bits/extc++.h>
#include <tr2/dynamic_bitset>
#define EXTS
#else
#ifdef ARST
#include <bits/clang++.h>
#else
#ifndef _GLIBCXX_NO_ASSERT
#include <cassert>
#endif
#include <cctype>
#include <cerrno>
#include <cfloat>
#include <ciso646>
#include <climits>
#include <clocale>
#include <cmath>
#include <csetjmp>
#include <csignal>
#include <cstdarg>
#include <cstddef>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <ctime>
#include <cwchar>
#include <cwctype>
#if __cplusplus >= 201103L
#include <ccomplex>
#include <cfenv>
#include <cinttypes>
// #include <cstdalign>
#include <cstdbool>
#include <cstdint>
#include <ctgmath>
// #include <cuchar>
#endif
#include <algorithm>
#include <bitset>
#include <complex>
#include <deque>
#include <exception>
#include <fstream>
#include <functional>
#include <iomanip>
#include <ios>
#include <iosfwd>
#include <iostream>
#include <istream>
#include <iterator>
#include <limits>
#include <list>
#include <locale>
#include <map>
#include <memory>
#include <new>
#include <numeric>
#include <ostream>
#include <queue>
#include <set>
#include <sstream>
#include <stack>
#include <stdexcept>
#include <streambuf>
#include <string>
#include <typeinfo>
#include <utility>
#include <valarray>
#include <vector>
#if __cplusplus >= 201103L
#include <array>
#include <atomic>
#include <chrono>
#include <codecvt>
#include <condition_variable>
#include <forward_list>
#include <future>
#include <initializer_list>
#include <mutex>
#include <random>
#include <ratio>
#include <regex>
#include <scoped_allocator>
#include <system_error>
#include <thread>
#include <tuple>
#include <typeindex>
#include <type_traits>
#include <unordered_map>
#include <unordered_set>
#endif
#if __cplusplus >= 201402L
#include <shared_mutex>
#endif
#if __cplusplus >= 201703L
#include <any>
#include <charconv>
// #include <execution>
#include <filesystem>
#include <optional>
// #include <memory_resource>
#include <string_view>
#include <variant>
#endif
#if __cplusplus >= 202002L
#include <barrier>
#include <bit>
#include <compare>
#include <concepts>
#if __cpp_impl_coroutine
# include <coroutine>
#endif
#include <latch>
#include <numbers>
#include <ranges>
#include <span>
// #include <stop_token>
#include <semaphore>
// #include <source_location>
// #include <syncstream>
#include <version>
#endif
#if __cplusplus > 202002L
// #include <expected>
// #include <spanstream>
#if __has_include(<stacktrace>)
# include <stacktrace>
#endif
#include <stdatomic.h>
#endif
#endif
#endif
#else
#error "unsupported"
#endif
#endif
using namespace std;
#ifdef ARST
#define JO 1
#define OJ 0
#else
#define JO 0
#define OJ 1
#endif
#define STR(x) #x
#define GCCDIAG(s) _Pragma(STR(GCC diagnostic s)) static_assert(true)
#define Wsave GCCDIAG(push)
#define Wpop GCCDIAG(pop)
#define Wsupp(w) GCCDIAG(ignored "-W" w)
#define Wpush(w) Wsave; Wsupp(w)
#define typeof __typeof__
namespace gbd_ns {
	template<typename C> struct is_iterable {
		template<class T> static long check(...);
		template<class T> static char check(int,typename T::const_iterator = C().end());
		enum {
			value = sizeof(check<C>(0)) == sizeof(char),
			neg_value = sizeof(check<C>(0)) != sizeof(char)
		};
	};
	template<class T> struct _gbd3C;
	template<class T> ostream &_gbd3(ostream &os,const T &x) { return _gbd3C<T>::call(os,x); }
	template<> ostream &_gbd3(ostream &os,const string &x) { return os<<'"'<<x<<'"'; }
	template<> ostream &_gbd3(ostream &os,char *const &x) { return os<<'"'<<x<<'"'; }
	template<class T> ostream &_gbd3_5(ostream &os,const T &x) { return _gbd3(os,x); }
	template<class A,class B> ostream &_gbd4(ostream &os,const pair<A,B> &p) {
		_gbd3(os<<'(',p.first);
		_gbd3(os<<',',p.second);
		return os<<')';
	}
	template<class T,size_t N> struct _gbd4_tupleC {
		static void call(ostream &os,const T &t) {
			_gbd4_tupleC<T,N-1>::call(os,t);
			os<<','<<get<N-1>(t);
		}
	};
	template<class T> struct _gbd4_tupleC<T,1> {
		static void call(ostream &os,const T &t) { os<<get<0>(t); }
	};
	template<typename... Types> ostream &_gbd4(ostream &os,const tuple<Types...> &t) {
		os<<'(';
		_gbd4_tupleC<tuple<Types...>,sizeof...(Types)>::call(os,t);
		return os<<')';
	}
	template<> ostream &_gbd4(ostream &os,const tuple<> &t) { (void)t; return os<<"()"; }
	template<class T> ostream &_gbd4(ostream &os,const T &x) {
		return os<<x;
	}
	template<class T> struct _gbd3C {
		template<class U=T> static ostream &call(ostream &os,enable_if_t<is_iterable<U>::value,const T> &V) {
			os<<"{";
			bool ff=0;
			for(const auto &E:V) _gbd3_5<decltype(E)>(ff?os<<",":os,E), ff=1;
			return os<<"}";
		}
		template<class U=T> static ostream &call(ostream &os,enable_if_t<is_iterable<U>::neg_value,const T> &x) {
			return _gbd4(os,x);
		}
	};
	template<class T,typename... Args> ostream &_gbd2(ostream &os,bool,vector<string>::iterator nm,const T &x,Args&&... args);
	ostream &_gbd2(ostream &os,bool,vector<string>::iterator) { return os; }
	template<typename... Args> ostream &_gbd2(ostream &os,bool fi,vector<string>::iterator nm,const char *x,Args&&... args) {
		return _gbd2(os<<(fi?"":"  ")<<x,0,nm+1,args...);
	}
	template<class T,typename... Args> ostream &_gbd2(ostream &os,bool fi,vector<string>::iterator nm,const T &x,Args&&... args) {
		return _gbd2(_gbd3<T>(os<<(fi?"":"  ")<<*nm<<"=",x),0,nm+1,args...);
	}
	vector<string> split(string s) {
		vector<string> Z;
		string z="";
		s+=',';
		int dep=0;
		for(char c:s) {
			if(c==',' && !dep) Z.push_back(z),z="";
			else z+=c;
			if(c=='(' || c=='{' || c=='[') ++dep;
			if(c==')' || c=='}' || c==']') --dep;
		}
		return Z;
	}
	template<typename... Args> ostream &_gbd1(ostream &os,const string &nm,Args&&... args) {
		return _gbd2(os,1,split(nm).begin(),args...);
	}
	template<typename... Args> string _gbd1(const string &nm,Args&&... args) {
		ostringstream oss;
		_gbd2(oss,1,split(nm).begin(),args...);
		return oss.str();
	}
}
bool DBG=1,EMACS=0;
#define dbg(...) (JO&&DBG?gbd_ns::_gbd1(cerr<<"\033[38;5;5m"<<__FILE__<<":"<<__LINE__<<(EMACS?":note: ":": "),#__VA_ARGS__,__VA_ARGS__)<<"\033[0m"<<endl:cerr)
#define dbgt(...) dbg(fmt_time(),__VA_ARGS__)
#define fmt(...) gbd_ns::_gbd1(#__VA_ARGS__,__VA_ARGS__)
template<class Fun> struct _y_combinator_result {
	Fun _fun;
	template<class T> explicit _y_combinator_result(T &&fun) : _fun(forward<T>(fun)) {}
	template<typename... Args> decltype(auto) operator()(Args&&... args) {
		return _fun(ref(*this),forward<Args>(args)...);
	}
};
template<class Fun> [[nodiscard]] decltype(auto) fix(Fun &&fun) {
	return _y_combinator_result<decay_t<Fun>>(forward<Fun>(fun));
}
#define nop void()
#define sz(x) (int((x).size()))
#define all(v) (v).begin(),(v).end()
#define forenum(i,...) for(int i:{-1}) for(__VA_ARGS__) if(++i,0) assert(0); else
#define forenumll(i,...) for(long long i:{-1}) for(__VA_ARGS__) if(++i,0) assert(0); else
#define forbs(k,i,bs) for(ptrdiff_t k=0,i=(bs)._Find_first();i<(ptrdiff_t)(bs).size();i=(bs)._Find_next(i),++k)
#define fordbs(k,i,bs) for(ptrdiff_t k=0,i=(bs).find_first();i<(ptrdiff_t)(bs).size();i=(bs).find_next(i),++k)
#define get(x,i) get<i>(x)
template<class T> T &smin(T &x,const T &y) { return y<x?x=y:x; }
template<class T> T &smax(T &x,const T &y) { return y>x?x=y:x; }
template<class T> bool inb(const T &x,const T &l,const T &r) { return l<=x&&x<=r; }
template<class T> bool cinb(const T &x,const T &l,const T &r) { return l<=r?l<=x&&x<=r:l<=x||x<=r; }
#define fi first
#define se second
#define pb push_back
#define eb emplace_back
template<template<class> class C,class T> T popv(C<T> &v) { T z=v.back(); v.pop_back(); return z; }
template<template<class> class C,class T> T popq(C<T> &v) { T z=v.front(); v.pop(); return z; }
template<template<class> class C,class T> T pops(C<T> &v) { T z=*v.begin(); v.erase(v.begin()); return z; }
template<template<class,class> class C,class K,class V> pair<K,V> popm(C<K,V> &v) { pair<K,V> z=*v.begin(); v.erase(v.begin()); return z; }
template<template<class> class C,class T> void erase1(C<T> &v,const T &x) { v.erase(v.find(x)); }
template<template<class> class C,class T> int lbi(C<T> &v,const T &x) { return int(lower_bound(all(v),x)-v.begin()); }
template<template<class> class C,class T> int findi(C<T> &v,const T &x) { auto it=lower_bound(all(v),x); return it!=v.end()&&*it==x?int(it-v.begin()):-1; }
template<class V> int sortu(V &v) { sort(all(v)); int z=int(unique(all(v))-v.begin()); v.resize(z); return z; }
template<typename T,typename... Args> T tee(T (*f)(Args... args),Args&&... args) { T z=f(forward<Args>(args)...); cout<<z<<endl; return z; }
template<typename... Args> void tee(void (*f)(Args... args),Args&&... args) { f(forward<Args>(args)...); }
#ifdef EXTS
template<class S,class T> using omap=__gnu_pbds::tree<S,T,less<S>,__gnu_pbds::rb_tree_tag,__gnu_pbds::tree_order_statistics_node_update>;
template<class T> using oset=omap<T,__gnu_pbds::null_type>;
template<class T> using rope=__gnu_cxx::rope<T>;
using dbitset=tr2::dynamic_bitset<>;
#endif
constexpr int e0=1, e1=10, e2=100, e3=1000;
constexpr int e4=10*e3, e5=100*e3, e6=1000*e3;
constexpr int e7=10*e6, e8=100*e6, e9=1000*e6;
constexpr long long e10=10LL*e9, e11=100LL*e9, e12=1000LL*e9;
constexpr long long e13=10*e12, e14=100*e12, e15=1000*e12;
constexpr long long e16=10*e15, e17=100*e15, e18=1000*e15;
constexpr __int128_t e21=__int128_t(e3)*e18, e24=__int128_t(e6)*e18, e27=__int128_t(e9)*e18;
constexpr __int128_t e30=e3*e27, e33=e6*e27, e36=e9*e27;
using ulll=__uint128_t;
using lll=__int128_t;
using ull=unsigned long long;
using ll=long long;
using uint=unsigned int;
using ushort=unsigned short;
using uchar=char;
using ld=long double;
#ifdef EXTS
using lld=__float128;
#endif
long long START_TIME=chrono::duration_cast<chrono::microseconds>(chrono::steady_clock::now().time_since_epoch()).count();
inline long long now_U_03BC_s() { return chrono::duration_cast<chrono::microseconds>(chrono::steady_clock::now().time_since_epoch()).count()-START_TIME; }
const char *fmt_time(long long U_03BC_s=now_U_03BC_s()) { static char dur[20]; sprintf(dur,"%llu.%03llus",U_03BC_s/e6,(U_03BC_s%e6)/e3); return dur; }
#define timed(cb) do { dbg("timed "#cb" ..."); unsigned long long start=now_U_03BC_s(); cb; dbg("timed "#cb" took",fmt_time(now_U_03BC_s()-start)); } while(0)
int arg1; bool inp; vector<string> args;
unsigned seed=unsigned(JO&&getenv("sd")?atoi(getenv("sd")):OJ?START_TIME:START_TIME%e5);
mt19937 igen(seed<<1),gen(seed<<1|1);
#define irand(...) (assert(!inp),_rand(igen,__VA_ARGS__))
#define rand(...) _rand(gen,__VA_ARGS__)
template<class T> enable_if_t<numeric_limits<T>::is_integer,T> _rand(mt19937 &g,T l,T r) { return uniform_int_distribution<T>(l,r)(g); }
template<class T> enable_if_t<numeric_limits<T>::is_integer,T> _rand(mt19937 &g,T n) { return _rand(g,T(1),n); }
[[deprecated]] int _rand(mt19937 &g) { return _rand(g,0,numeric_limits<int>::max()); }
template<class T> enable_if_t<numeric_limits<T>::is_iec559,T> _rand(mt19937 &g,T l,T r) { return uniform_real_distribution<T>(l,r)(g); }
bool _rand(mt19937 &g,double p) { return bernoulli_distribution(p)(g); }
template<class T> T _rand(mt19937 &g,initializer_list<T> il) { return *(il.begin()+_rand(g,0,(int)il.size()-1)); }
template<class T> T _rand(mt19937 &g,double p,T a,T b) { return _rand(g,p)?a:b; }
template<class T> T _rand(mt19937 &g,initializer_list<T> il,initializer_list<double> wt) { assert(il.size()==wt.size()); return *(il.begin()+discrete_distribution<int>(wt)(g)); }
#define random_shuffle(...) static_assert(false,"random_shuffle deprecated, use shuffle")
#define ine(x,e) (inp?cin>>(x),nop:((x)=(e),nop))
#define inr(x,...) ine(x,irand(__VA_ARGS__))
#define endl '\n'
string garb;
void exit0() { DBG=1; dbgt("gg (early)",seed); exit(0); }
#ifndef MAIN
#define MAIN _main
#endif
void MAIN();
int32_t main([[maybe_unused]]int argc,[[maybe_unused]]char *argv[]) {
	ios_base::sync_with_stdio(0); cin.tie(0); cin.exceptions(ios_base::failbit | ios_base::badbit);
	arg1=0,args={argv,argv+argc};
	if(sz(args)>1) {
		if(args[1][0]=='i') freopen((string(__FILE__).substr(0,string(__FILE__).find('.'))+"."+args[1].substr(1)+".in").c_str(),"r",stdin);
		else if(args[1][0]=='I') freopen(args[1].substr(1).c_str(),"r",stdin);
		else arg1=stoi(args[1]);
	}
	inp=!arg1;
	if(JO && getenv("EMACS")) EMACS=1;
	dbgt(arg1,seed,args);
	#ifdef QUIET
	DBG=0;
	#endif
	MAIN();
	DBG=1;
	dbgt("gg;wp",seed);
	return 0;
}
constexpr int inf=e9+99;
constexpr ll linf=1LL*e9*e9+99;
#if __cplusplus >= 202002L
constexpr long double U_03C4__ld=2*numbers::pi_v<long double>;
#else
const long double U_03C4__ld=2*acosl(-1);
#endif
#define U_03C4_ ((flt)U_03C4__ld)
constexpr long double U_03B5__ld=1e-8l;
#define U_03B5_ ((flt)U_03B5__ld)
// }}}
using flt=double; //CARE
constexpr int P=998'244'353;

int powq(int x,int e) {
	int z=1;
	for(;e;e>>=1,x=int(1LL*x*x%P)) if(e&1) z=int(1LL*z*x%P);
	return z;
}
void add(int &x,int y) { if((x+=y)>=P) x-=P; }

const int N=1<<20;
int F(int n) {
	static int dp[N];
	int &ans=dp[n];
	if(ans) return ans;
	if(!n) return ans=1;
	return ans=int(1LL*F(n-1)*n%P);
}
int iF(int n) {
	static int dp[N];
	int &ans=dp[n];
	if(ans) return ans;
	if(n==N-1) return ans=powq(F(n),P-2);
	return ans=int(1LL*iF(n+1)*(n+1)%P);
}

int C(int n,int k) {
	return int(1LL*F(n)*iF(k)%P*iF(n-k)%P);
}


auto solve() { /* CURSOR START */
	int K; ine(K,arg1);
	static int z[N];
	for(int i=0;i<=2*K;i++) z[i]=C(2*K,i);
	add(z[0],P-powq(2,K));
	dbg(vector<int>(z,z+2*K+2));

	int i2=(P+1)/2;
	for(int i=0;i<=2*K+2;i++) {
		// z[i]=int(1LL*z[i]*i2%P);
		add(z[i+1],z[i]);
		add(z[i+1],z[i]);
		add(z[i+2],z[i]);
		if(z[i]) z[i]=P-z[i];
	}
	dbg(vector<int>(z,z+2*K+4));
	// assert(!z[0]);
	// for(int i=0;i<2*K;i++) z[i]=z[i+2];
	// z[2*K]=0;

	for(int i=0;i<=K;i++) add(z[i],C(K,i));
	for(int i=0;i<=K;i++) add(z[i],C(K,i));
	add(z[1],1);
	dbg(vector<int>(z,z+2*K+2));
	assert(z[0]-1==powq(2,K));
	// assert(!z[0]);

	for(int i=1;i<=2*K-2;i++) cout<<z[i]<<" \n"[i==2*K-2];
}



void _main() { int NTC=1;
	// ine(NTC,5);
	for(int TC=1;TC<=NTC;TC++) {
		// cout<<"Case #"<<TC<<": ";
		tee(solve);
	}
	if(JO&&inp) assert((cin>>ws).eof());
}

Details

Tip: Click on the bar to expand more detailed information

Test #1:

score: 100
Accepted
time: 23ms
memory: 60948kb

input:

2

output:

7 3

result:

ok 2 tokens

Test #2:

score: 0
Accepted
time: 8ms
memory: 61024kb

input:

3

output:

15 14 6 1

result:

ok 4 tokens

Test #3:

score: 0
Accepted
time: 20ms
memory: 60960kb

input:

4

output:

31 43 36 19 6 1

result:

ok 6 tokens

Test #4:

score: 0
Accepted
time: 15ms
memory: 60956kb

input:

5

output:

63 110 132 114 70 30 8 1

result:

ok 8 tokens

Test #5:

score: 0
Accepted
time: 25ms
memory: 61140kb

input:

6

output:

127 255 384 448 400 272 136 47 10 1

result:

ok 10 tokens

Test #6:

score: 0
Accepted
time: 19ms
memory: 60956kb

input:

7

output:

255 558 978 1401 1610 1478 1066 589 240 68 12 1

result:

ok 12 tokens

Test #7:

score: 0
Accepted
time: 25ms
memory: 60888kb

input:

8

output:

511 1179 2292 3803 5250 5987 5576 4183 2482 1137 388 93 14 1

result:

ok 14 tokens

Test #8:

score: 0
Accepted
time: 7ms
memory: 61028kb

input:

9

output:

1023 2438 5088 9398 14896 20038 22632 21250 16406 10282 5144 2006 588 122 16 1

result:

ok 16 tokens

Test #9:

score: 0
Accepted
time: 16ms
memory: 60984kb

input:

10

output:

2047 4975 10896 21772 38360 58724 77184 86312 81448 64324 42112 22576 9744 3304 848 155 18 1

result:

ok 18 tokens

Test #10:

score: 0
Accepted
time: 21ms
memory: 61032kb

input:

11

output:

4095 10070 22782 48209 92140 156292 232068 298744 330926 313422 252186 171122 97008 45368 17200 5155 1176 192 20 1

result:

ok 20 tokens

Test #11:

score: 0
Accepted
time: 79ms
memory: 49200kb

input:

500000

output:

390220183 534638705 182393715 303662724 176884209 76063846 314206329 970463075 138271132 869076105 902568877 121426660 599330372 720576343 535733058 609095360 499854676 427738345 789967637 850801793 767689169 103101879 573005863 597231280 725469375 299015007 178535851 966708332 305629 940093777 7830...

result:

ok 999998 tokens

Test #12:

score: 0
Accepted
time: 33ms
memory: 59476kb

input:

72787

output:

863191949 852718765 363831665 964981186 487891193 263854743 37522806 18985671 265243835 698211861 413341848 452649596 684165069 41891590 781946347 633808644 213891845 90859042 654886506 681500079 853399752 536402628 160278411 189221861 144879826 449123001 395247186 477700669 245829076 740028721 3991...

result:

ok 145572 tokens

Test #13:

score: 0
Accepted
time: 31ms
memory: 60504kb

input:

29621

output:

625188972 186328126 837166229 677006047 662339899 556164288 627678499 464879587 574719635 860749906 37224574 952205162 612486418 67731480 127518779 222659320 311864904 739493528 441208728 656349279 675863661 193365665 871786422 429030382 542544944 65332274 279132780 886986640 23673291 260179258 1458...

result:

ok 59240 tokens

Test #14:

score: 0
Accepted
time: 44ms
memory: 54928kb

input:

287834

output:

839249597 106353691 541743754 176289649 331709790 90695814 581166563 660013633 12148749 777570497 239549256 50822832 928845641 783688014 527134794 967565837 8829067 728890387 532021836 723133136 271356603 442733913 109610442 872231778 997519892 627636901 942495046 612005045 480787271 380535891 31598...

result:

ok 575666 tokens

Test #15:

score: 0
Accepted
time: 51ms
memory: 52460kb

input:

372458

output:

238073678 125575487 257781224 432208434 926232022 985032784 972531646 156874450 242230869 958239072 623209641 963804956 760997596 492384034 248852029 480721426 727545366 871518883 526580215 340703419 119254798 894452847 503218079 466661994 21196998 64609258 607451189 866020376 472431142 833623174 95...

result:

ok 744914 tokens

Test #16:

score: 0
Accepted
time: 52ms
memory: 54164kb

input:

326174

output:

182767154 379158505 976650370 950752234 730142912 199366602 217176449 58415818 942059311 29041812 600728528 238722381 35842882 619426938 166582941 887411034 365366704 226747213 653768421 675658473 198607105 971515601 49241364 300610682 741576498 580333820 788122734 812899883 506754294 906735361 8477...

result:

ok 652346 tokens

Test #17:

score: 0
Accepted
time: 61ms
memory: 51200kb

input:

414785

output:

119371452 447324155 812098442 674259707 906095700 995739643 507821850 144836991 944844465 417859866 526136325 446179637 841143258 71594396 600687837 115917880 869472132 733304409 785178785 942797825 461532099 569481220 498200557 562246854 231360418 806781417 603555993 817444062 8765767 415391941 188...

result:

ok 829568 tokens

Test #18:

score: 0
Accepted
time: 19ms
memory: 61888kb

input:

52410

output:

109025791 520279794 997868526 544815757 1210333 262602454 444694081 215482612 359518123 630972106 469202475 93255040 356550496 552798085 978002390 758808807 872405738 26538225 591804454 180245449 487598812 486435998 100463040 636978431 131160375 54547501 21577758 600993423 54379208 278755072 3851668...

result:

ok 104818 tokens

Test #19:

score: 0
Accepted
time: 56ms
memory: 55364kb

input:

266488

output:

670591955 536664499 834582667 435202901 981715449 216606476 24885754 288060317 473842053 728197980 859018006 359189535 188879878 589394421 415307716 612098332 697672094 255330112 873094951 829240529 612715926 251238400 811393752 657428602 471660768 508314629 890321558 248471292 52873644 528909339 36...

result:

ok 532974 tokens

Test #20:

score: 0
Accepted
time: 44ms
memory: 56388kb

input:

235412

output:

838376130 82261816 749813798 853852768 548463514 590159263 767906723 873538508 681808483 793716931 81414518 387819437 489838184 649414809 971267048 518919507 299233671 402683441 670109161 673246099 315748962 982292160 524024775 990312514 930875705 394644470 79309906 651862394 296416662 949936814 511...

result:

ok 470822 tokens

Test #21:

score: 0
Accepted
time: 65ms
memory: 53728kb

input:

335028

output:

412572542 90575816 592590793 134956941 681546461 84123901 23797401 287575357 580630562 822219941 496015371 798714568 996561274 228437956 38964111 210338108 447304705 455001788 541599590 15999929 531678296 86106708 417035208 77019361 258493500 3295255 609295926 388289340 12082287 479955282 13536114 5...

result:

ok 670054 tokens

Test #22:

score: 0
Accepted
time: 60ms
memory: 49432kb

input:

490193

output:

89108812 9400903 759083927 482137918 881472778 819325246 469847190 224397125 941016878 318853318 823063910 192963094 253539854 195834928 305679610 177655853 744021959 486473727 952943524 80929181 726898580 419500987 86904978 500273473 864375683 752394278 447105311 649043680 568500692 716331790 79426...

result:

ok 980384 tokens

Test #23:

score: 0
Accepted
time: 61ms
memory: 49500kb

input:

494427

output:

224396630 171699844 874970651 366738496 188097388 20105024 923005591 475213547 862579354 219327984 402729610 343802472 824016768 274735056 606982614 720737421 379273500 527635893 326566225 588809571 892479263 956818966 119334763 921549067 728518606 341094293 734579914 96978341 54880988 441706555 375...

result:

ok 988852 tokens

Test #24:

score: 0
Accepted
time: 75ms
memory: 49280kb

input:

495456

output:

176309560 31132799 871206936 191727597 372664218 912078745 128667682 749015357 783582110 969205654 792240671 185634038 963924594 739384852 286035580 546230295 777033259 473035706 331715612 919733935 140740960 188303720 108317267 957369642 570466063 215525809 161735173 289750332 41787886 592639789 24...

result:

ok 990910 tokens

Test #25:

score: 0
Accepted
time: 65ms
memory: 49260kb

input:

499498

output:

10762491 87744479 29345176 330762125 67139471 859322674 517319159 444257903 287766504 323230886 614147692 179153449 789116746 632670050 42290946 845385229 648164696 260416611 791349068 162962424 446055973 201137312 796950696 787484329 797523547 634752612 675290933 712512594 448869911 573190874 93885...

result:

ok 998994 tokens

Test #26:

score: 0
Accepted
time: 65ms
memory: 49620kb

input:

493812

output:

613558532 754129691 624537960 491192546 52587972 335888580 918154485 412643191 632432095 756789608 652622556 498719566 684849283 923391920 735537543 543746954 46908287 213544787 692082087 977892286 329586609 673904401 701415241 768595797 918191698 628376968 628786912 839407278 263562545 942236399 70...

result:

ok 987622 tokens

Extra Test:

score: 0
Extra Test Passed