提出 #765202
ソースコード 拡げる
import java.util.ArrayList;
import java.util.List;
import java.util.Scanner;
public class Main {
public static void main(String[] args){
Scanner sc = new Scanner(System.in);
int n = sc.nextInt();
int c = 0;
List<Integer> array = new ArrayList<Integer>();
for(int i = 0; i < n; i++){
array.add(sc.nextInt());
}
for(int i=0; i < n; i++) {
for(int j=i; j < n; j++){
//昇順判定
boolean flg = true;
if(i < j){
int k = i;
while(k < j) {
if(array.get(k) >= array.get(k+1)){
flg = false;
break;
}
k++;
}
}
if(flg) {
c++;
}
}
}
System.out.println(c);
}
}
提出情報
| 提出日時 | |
|---|---|
| 問題 | A - お茶 |
| ユーザ | eskinesics |
| 言語 | Java7 (OpenJDK 1.7.0) |
| 得点 | 0 |
| コード長 | 700 Byte |
| 結果 | RE |
| 実行時間 | 223 ms |
| メモリ | 8788 KiB |
ジャッジ結果
| セット名 | Sample | All | ||||
|---|---|---|---|---|---|---|
| 得点 / 配点 | 0 / 0 | 0 / 100 | ||||
| 結果 |
|
|
| セット名 | テストケース |
|---|---|
| Sample | sample_0.txt, sample_1.txt, sample_2.txt, sample_3.txt, sample_4.txt |
| All | subtask1_0.txt, subtask1_1.txt, subtask1_10.txt, subtask1_11.txt, subtask1_12.txt, subtask1_13.txt, subtask1_14.txt, subtask1_2.txt, subtask1_3.txt, subtask1_4.txt, subtask1_5.txt, subtask1_6.txt, subtask1_7.txt, subtask1_8.txt, subtask1_9.txt |
| ケース名 | 結果 | 実行時間 | メモリ |
|---|---|---|---|
| sample_0.txt | RE | 216 ms | 8788 KiB |
| sample_1.txt | RE | 216 ms | 8788 KiB |
| sample_2.txt | RE | 212 ms | 8788 KiB |
| sample_3.txt | RE | 212 ms | 8788 KiB |
| sample_4.txt | RE | 212 ms | 8788 KiB |
| subtask1_0.txt | RE | 219 ms | 8788 KiB |
| subtask1_1.txt | RE | 216 ms | 8788 KiB |
| subtask1_10.txt | RE | 219 ms | 8660 KiB |
| subtask1_11.txt | RE | 213 ms | 8788 KiB |
| subtask1_12.txt | RE | 219 ms | 8660 KiB |
| subtask1_13.txt | RE | 218 ms | 8660 KiB |
| subtask1_14.txt | RE | 212 ms | 8660 KiB |
| subtask1_2.txt | RE | 219 ms | 8788 KiB |
| subtask1_3.txt | RE | 221 ms | 8788 KiB |
| subtask1_4.txt | RE | 216 ms | 8660 KiB |
| subtask1_5.txt | RE | 220 ms | 8660 KiB |
| subtask1_6.txt | RE | 216 ms | 8660 KiB |
| subtask1_7.txt | RE | 223 ms | 8788 KiB |
| subtask1_8.txt | RE | 223 ms | 8788 KiB |
| subtask1_9.txt | RE | 216 ms | 8660 KiB |