結果

問題 No.2056 非力なレッド
ユーザー lanegue
提出日時 2022-08-26 22:14:55
言語 D
(dmd 2.109.1)
結果
AC  
実行時間 24 ms / 2,000 ms
コード長 357 bytes
コンパイル時間 2,270 ms
コンパイル使用メモリ 230,488 KB
実行使用メモリ 13,244 KB
最終ジャッジ日時 2024-06-22 16:07:37
合計ジャッジ時間 3,747 ms
ジャッジサーバーID
(参考情報)
judge2 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 38
権限があれば一括ダウンロードができます

ソースコード

diff #

import std;
void main(){
	auto input = readln.chomp.split(" ").to!(long[]);
	long N = input[0];
	long X = input[1];
	long M = input[2];
	auto A = readln.chomp.split(" ").to!(long[]);
	long count = 0;
	for(auto i = N - 1; i >= 0; i--){
		A[i] >>= count;
		while(A[i] >= X){
			A[i] >>= 1;
			count++;
			M -= i + 1;
		}
	}
	writeln(M >= 0 ? "Yes" : "No");
}
0