結果

問題 No.1183 コイン遊び
ユーザー jj1gujjj1guj
提出日時 2020-08-22 13:07:43
言語 Fortran
(gFortran 13.2.0)
結果
AC  
実行時間 223 ms / 2,000 ms
コード長 402 bytes
コンパイル時間 1,664 ms
コンパイル使用メモリ 31,872 KB
実行使用メモリ 18,580 KB
最終ジャッジ日時 2024-04-23 07:25:29
合計ジャッジ時間 8,562 ms
ジャッジサーバーID
(参考情報)
judge4 / judge2
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 2 ms
6,812 KB
testcase_01 AC 1 ms
6,944 KB
testcase_02 AC 1 ms
6,940 KB
testcase_03 AC 1 ms
6,940 KB
testcase_04 AC 1 ms
6,940 KB
testcase_05 AC 1 ms
6,944 KB
testcase_06 AC 1 ms
6,944 KB
testcase_07 AC 1 ms
6,940 KB
testcase_08 AC 2 ms
6,944 KB
testcase_09 AC 1 ms
6,944 KB
testcase_10 AC 6 ms
6,940 KB
testcase_11 AC 14 ms
6,940 KB
testcase_12 AC 136 ms
12,524 KB
testcase_13 AC 126 ms
11,464 KB
testcase_14 AC 211 ms
17,500 KB
testcase_15 AC 218 ms
18,484 KB
testcase_16 AC 220 ms
18,388 KB
testcase_17 AC 222 ms
18,456 KB
testcase_18 AC 223 ms
18,480 KB
testcase_19 AC 222 ms
18,476 KB
testcase_20 AC 221 ms
18,484 KB
testcase_21 AC 212 ms
18,548 KB
testcase_22 AC 222 ms
18,516 KB
testcase_23 AC 213 ms
18,340 KB
testcase_24 AC 217 ms
18,408 KB
testcase_25 AC 215 ms
18,440 KB
testcase_26 AC 219 ms
18,552 KB
testcase_27 AC 221 ms
18,336 KB
testcase_28 AC 220 ms
18,488 KB
testcase_29 AC 213 ms
18,336 KB
testcase_30 AC 214 ms
18,580 KB
testcase_31 AC 222 ms
18,344 KB
testcase_32 AC 218 ms
18,424 KB
testcase_33 AC 220 ms
18,384 KB
testcase_34 AC 214 ms
18,308 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

program main
    implicit none
    integer(8)::N,flg,i,ans=0
    integer(8),allocatable::A(:),B(:)
    read*,N
    allocate(A(N))
    allocate(B(N))
    read*,A,B

    flg=0
    do i=1,N
        if(A(i)/=B(i))then
            if(flg==0)then
                flg=1
                ans=ans+1
            end if
        else
            flg=0
        end if
    end do

    print'(i0)',ans
end program main
0