結果

問題 No.865 24時間降水量
ユーザー tailstails
提出日時 2019-08-16 23:03:02
言語 cLay
(20231016-1)
結果
TLE  
(最新)
AC  
(最初)
実行時間 -
コード長 248 bytes
コンパイル時間 1,965 ms
コンパイル使用メモリ 160,992 KB
実行使用メモリ 11,776 KB
最終ジャッジ日時 2023-09-19 00:24:40
合計ジャッジ時間 9,471 ms
ジャッジサーバーID
(参考情報)
judge12 / judge15
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 TLE -
testcase_01 -- -
testcase_02 -- -
testcase_03 -- -
testcase_04 -- -
testcase_05 -- -
testcase_06 -- -
testcase_07 -- -
testcase_08 -- -
testcase_09 -- -
testcase_10 -- -
testcase_11 -- -
testcase_12 -- -
testcase_13 -- -
testcase_14 -- -
testcase_15 -- -
testcase_16 -- -
testcase_17 -- -
testcase_18 -- -
testcase_19 -- -
testcase_20 -- -
権限があれば一括ダウンロードができます
コンパイルメッセージ
main.cpp: In function ‘long long int f(long long int, long long int)’:
main.cpp:143:1: warning: no return statement in function returning non-void [-Wreturn-type]
 }
 ^

ソースコード

diff #

ll n,a[2d5],q,t,v;
ll b,s;
ll f(ll x,ll y){
	s=0;
	rep(i,max(0,x-24),t){
		s+=a[i];
	}
	rep(i,t,min(n,y)){
		s+=a[i];
		if(i-24>=0) s-=a[i-24];
		if(b<s) b=s;
	}
}
{
	rd(n,a(n),q);
	f(0,n);
	rep(q){
		rd(t,v);
		a[--t]=v;
		f(t,t+24);
		wt(b);
	}
}
0