結果
問題 |
No.675 ドットちゃんたち
|
ユーザー |
|
提出日時 | 2018-04-18 20:35:26 |
言語 | Python2 (2.7.18) |
結果 |
RE
|
実行時間 | - |
コード長 | 368 bytes |
コンパイル時間 | 98 ms |
コンパイル使用メモリ | 6,940 KB |
実行使用メモリ | 6,948 KB |
最終ジャッジ日時 | 2024-06-27 04:33:45 |
合計ジャッジ時間 | 1,135 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | RE * 4 |
other | RE * 8 |
ソースコード
from numpy import* n,x,y=map(int,raw_input().split()) a=[array([[1,0,c[1]],[0,1,0],[0,0,1]]) if c[0]==1 else array([[1,0,0],[0,1,c[1]],[0,0,1]]) if c[0]==2 else array([[0,1,0],[-1,0,0],[0,0,1]]) for c in [map(int,raw_input().split()) for _ in range(n)]] for i in range(n-2,-1,-1): a[i]=dot(a[i+1],a[i]) for i in range(n): print ' '.join(map(str,dot(a[i],[x,y,1])[:2]))