結果

問題 No.2441 行列累乗
ユーザー t98slidert98slider
提出日時 2023-06-10 10:06:10
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 131 ms / 2,000 ms
コード長 173 bytes
コンパイル時間 108 ms
コンパイル使用メモリ 10,652 KB
実行使用メモリ 29,624 KB
最終ジャッジ日時 2023-08-30 20:03:20
合計ジャッジ時間 5,891 ms
ジャッジサーバーID
(参考情報)
judge13 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 126 ms
29,544 KB
testcase_01 AC 126 ms
29,624 KB
testcase_02 AC 125 ms
29,504 KB
testcase_03 AC 122 ms
29,480 KB
testcase_04 AC 123 ms
29,532 KB
testcase_05 AC 122 ms
29,496 KB
testcase_06 AC 126 ms
29,520 KB
testcase_07 AC 124 ms
29,508 KB
testcase_08 AC 125 ms
29,548 KB
testcase_09 AC 131 ms
29,552 KB
testcase_10 AC 126 ms
29,480 KB
testcase_11 AC 124 ms
29,448 KB
testcase_12 AC 124 ms
29,548 KB
testcase_13 AC 126 ms
29,480 KB
testcase_14 AC 126 ms
29,544 KB
testcase_15 AC 129 ms
29,444 KB
testcase_16 AC 128 ms
29,436 KB
testcase_17 AC 128 ms
29,596 KB
testcase_18 AC 130 ms
29,564 KB
testcase_19 AC 127 ms
29,464 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys
import numpy as np

a, b = map(int, input().split())
c, d = map(int, input().split())
M = np.matrix([[a, b], [c, d]])

np.savetxt(sys.stdout, M * M * M, fmt='%i')
0