結果
問題 |
No.40 多項式の割り算
|
ユーザー |
![]() |
提出日時 | 2017-03-20 05:36:43 |
言語 | Fortran (gFortran 14.2.0) |
結果 |
AC
|
実行時間 | 3 ms / 5,000 ms |
コード長 | 430 bytes |
コンパイル時間 | 178 ms |
コンパイル使用メモリ | 32,256 KB |
実行使用メモリ | 5,376 KB |
最終ジャッジ日時 | 2024-07-05 00:40:18 |
合計ジャッジ時間 | 1,392 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 32 |
ソースコード
program main implicit none integer*8::DA integer*8,allocatable::a(:) integer*8::b(0:2),asum integer::i read *,DA allocate(a(0:DA)) read *,a(0:DA) asum = SUM(a(1:DA)) b(0) = a(0) b(1) = SUM(a(1:DA:2)) b(2) = asum -b(1) if(b(2).ne.0) then print '("2",/,i0,1x,i0,1x,i0)', b else if(b(1).ne.0) then print '("1",/,i0,1x,i0)', b(0:1) else print '("0",/i0)', b(0) end if end program main