結果

問題 No.1047 Zero (Novice)
ユーザー StarMatyanStarMatyan
提出日時 2020-11-28 00:19:31
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
RE  
実行時間 -
コード長 315 bytes
コンパイル時間 718 ms
コンパイル使用メモリ 10,484 KB
実行使用メモリ 7,984 KB
最終ジャッジ日時 2023-10-09 22:54:12
合計ジャッジ時間 1,348 ms
ジャッジサーバーID
(参考情報)
judge11 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 RE -
testcase_01 WA -
testcase_02 RE -
testcase_03 WA -
testcase_04 RE -
testcase_05 WA -
testcase_06 AC 15 ms
7,928 KB
testcase_07 RE -
testcase_08 RE -
testcase_09 RE -
testcase_10 RE -
testcase_11 RE -
testcase_12 RE -
testcase_13 RE -
testcase_14 AC 15 ms
7,788 KB
testcase_15 AC 15 ms
7,832 KB
testcase_16 RE -
testcase_17 WA -
testcase_18 RE -
testcase_19 AC 15 ms
7,888 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

inputer = input()
inputer_s = inputer.split(" ")

a_num = int(inputer[0])
b_num = int(inputer[1])
result = 0

if b_num==0:
	result = 1
elif a_num == 0:
	result = -1
else:
	if b_num > 0:
		if a_num < 0:
			result=2
		else:
			result=-1
	elif b_num < 0:
		if a_num > 0:
			result=2
		else:
			result=-1

print(result)
0