結果

問題 No.1175 Simultaneous Equations
ユーザー 37zigen37zigen
提出日時 2020-08-21 21:39:44
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 462 ms / 2,000 ms
コード長 180 bytes
コンパイル時間 79 ms
コンパイル使用メモリ 12,800 KB
実行使用メモリ 44,060 KB
最終ジャッジ日時 2024-04-23 05:40:18
合計ジャッジ時間 6,820 ms
ジャッジサーバーID
(参考情報)
judge5 / judge3
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 462 ms
43,804 KB
testcase_01 AC 459 ms
44,060 KB
testcase_02 AC 445 ms
44,060 KB
testcase_03 AC 444 ms
43,676 KB
testcase_04 AC 438 ms
43,808 KB
testcase_05 AC 439 ms
43,924 KB
testcase_06 AC 441 ms
43,680 KB
testcase_07 AC 439 ms
43,932 KB
testcase_08 AC 446 ms
43,944 KB
testcase_09 AC 447 ms
43,676 KB
testcase_10 AC 444 ms
43,940 KB
testcase_11 AC 442 ms
43,680 KB
testcase_12 AC 449 ms
43,680 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import numpy as np
a,b,c,d,e,f=map(int,input().split())
det=a*e-b*d
mat=np.array([[e,-b],[-d,a]])
vec=np.array([[c],[f]])
mat=mat/det
vec=np.dot(mat,vec)
print(vec[0][0],vec[1][0])
0