結果

問題 No.55 正方形を描くだけの簡単なお仕事です。
ユーザー 👑 tatt61880tatt61880
提出日時 2021-03-20 17:52:40
言語 Kuin
(KuinC++ v.2021.9.17)
結果
WA  
実行時間 -
コード長 652 bytes
コンパイル時間 2,407 ms
コンパイル使用メモリ 153,576 KB
実行使用メモリ 4,356 KB
最終ジャッジ日時 2023-10-14 17:43:38
合計ジャッジ時間 3,347 ms
ジャッジサーバーID
(参考情報)
judge14 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 2 ms
4,348 KB
testcase_01 AC 2 ms
4,348 KB
testcase_02 WA -
testcase_03 WA -
testcase_04 AC 2 ms
4,352 KB
testcase_05 AC 1 ms
4,352 KB
testcase_06 AC 2 ms
4,352 KB
testcase_07 AC 1 ms
4,352 KB
testcase_08 AC 2 ms
4,348 KB
testcase_09 AC 2 ms
4,352 KB
testcase_10 AC 1 ms
4,352 KB
testcase_11 WA -
testcase_12 AC 1 ms
4,348 KB
testcase_13 WA -
testcase_14 WA -
testcase_15 AC 2 ms
4,352 KB
testcase_16 WA -
testcase_17 AC 2 ms
4,352 KB
testcase_18 AC 1 ms
4,352 KB
testcase_19 AC 1 ms
4,348 KB
testcase_20 WA -
testcase_21 WA -
testcase_22 WA -
testcase_23 WA -
testcase_24 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

func main()
	var pos: [][]int :: #[3, 2]int
	for i(0, 2)
		do pos[i] :: [cui@inputInt(), cui@inputInt()]
	end for
	for i(0, 2)
		do swap(&pos[i], &pos[0])
		if((pos[1][0] - pos[0][0]) * (pos[2][0] - pos[0][0]) + (pos[1][1] - pos[0][1]) * (pos[2][1] - pos[0][1]) = 0)
			if((pos[1][0] - pos[0][0]) ^ 2 + (pos[1][1] - pos[0][1]) ^ 2 = (pos[2][0] - pos[0][0]) ^ 2 + (pos[2][1] - pos[0][1]) ^ 2)
				do cui@print("\{pos[2][0] + pos[1][0] - pos[0][0]} \{pos[2][1] + pos[1][1] - pos[0][1]}\n")
				ret
			end if
		end if
	end for
	
	do cui@print("-1\n")
	
	func swap(a: &[]int, b: &[]int)
		var t: []int :: ##a
		do a :: ##b
		do b :: ##t
	end func
end func
0