結果
問題 |
No.905 Sorted?
|
ユーザー |
![]() |
提出日時 | 2019-10-12 13:19:00 |
言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
結果 |
TLE
|
実行時間 | - |
コード長 | 314 bytes |
コンパイル時間 | 93 ms |
コンパイル使用メモリ | 12,672 KB |
実行使用メモリ | 39,152 KB |
最終ジャッジ日時 | 2024-11-27 19:35:54 |
合計ジャッジ時間 | 27,912 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 15 TLE * 8 |
ソースコード
def dec(a): if a == sorted(a,reverse=True):return 1 else:return 0 def inc(a): if a == sorted(a):return 1 else:return 0 N = int(input()) a = list(map(int,input().split())) Q = int(input()) for _ in range(Q): b,c = map(int,input().split()) targ = a[b:c+1] print(inc(targ),dec(targ))