結果

問題 No.1471 Sort Queries
ユーザー 沙耶花沙耶花
提出日時 2021-04-09 23:33:57
言語 C++17
(gcc 12.3.0 + boost 1.83.0)
結果
TLE  
実行時間 -
コード長 428 bytes
コンパイル時間 4,457 ms
コンパイル使用メモリ 261,204 KB
実行使用メモリ 8,768 KB
最終ジャッジ日時 2023-09-07 18:31:21
合計ジャッジ時間 13,992 ms
ジャッジサーバーID
(参考情報)
judge13 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 2 ms
4,504 KB
testcase_01 AC 1 ms
4,376 KB
testcase_02 AC 2 ms
4,380 KB
testcase_03 AC 2 ms
4,388 KB
testcase_04 AC 2 ms
4,376 KB
testcase_05 AC 2 ms
4,380 KB
testcase_06 AC 1 ms
4,376 KB
testcase_07 AC 2 ms
4,380 KB
testcase_08 AC 1 ms
4,380 KB
testcase_09 AC 2 ms
4,376 KB
testcase_10 AC 1 ms
4,376 KB
testcase_11 AC 2 ms
4,380 KB
testcase_12 AC 2 ms
4,380 KB
testcase_13 AC 100 ms
4,380 KB
testcase_14 AC 85 ms
4,376 KB
testcase_15 AC 160 ms
4,380 KB
testcase_16 AC 32 ms
4,376 KB
testcase_17 AC 70 ms
4,380 KB
testcase_18 AC 46 ms
4,380 KB
testcase_19 AC 42 ms
4,376 KB
testcase_20 AC 162 ms
4,376 KB
testcase_21 AC 76 ms
4,380 KB
testcase_22 AC 60 ms
4,376 KB
testcase_23 AC 362 ms
4,380 KB
testcase_24 AC 355 ms
4,380 KB
testcase_25 AC 582 ms
4,380 KB
testcase_26 AC 312 ms
4,376 KB
testcase_27 AC 528 ms
4,376 KB
testcase_28 AC 527 ms
4,380 KB
testcase_29 AC 308 ms
4,380 KB
testcase_30 AC 336 ms
4,512 KB
testcase_31 AC 549 ms
4,380 KB
testcase_32 AC 456 ms
4,376 KB
testcase_33 TLE -
testcase_34 -- -
testcase_35 -- -
testcase_36 -- -
testcase_37 -- -
testcase_38 -- -
testcase_39 -- -
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <stdio.h>
#include <atcoder/all>
#include <bits/stdc++.h>
using namespace std;
using namespace atcoder;
using mint = modint1000000007;
#define rep(i,n) for (int i = 0; i < (n); ++i)
#define Inf 1000000000

int main(){
	
	int n,q;
	cin>>n>>q;
	
	string s;
	cin>>s;
	
	rep(i,q){
		
		int l,r,x;
		cin>>l>>r>>x;
		l--;
		string t = s.substr(l,r-l);
		sort(t.begin(),t.end());
		cout<<t[x-1]<<endl;
		
	}
	
    return 0;
}
0