본문 바로가기
Programming Practice/Python

백준 5086 파이썬 배수와 약수

by TAMIK 2023. 9. 3.
728x90

배수와 약수

#B5086
while True:
	a, b = map(int, input().split())
	if a<b and b%a==0:
		print("factor")
	elif a>b and a%b==0:
		print("multiple")
	elif a==0 and b==0:
		break
	else:
		print("neither")
728x90