1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 | # # µû¶óÇÏ¸ç ¹è¿ì´Â ÆÄÀ̽ã°ú µ¥ÀÌÅÍ°úÇÐ(»ý´ÉÃâÆÇ»ç 2020) # 8.10 µÎ ¼öÀÇ ¾à¼ö¿Í ÃÖ´ë°ø¾à¼ö ±×¸®°í ÇÁ·Î±×·¡¹ÖÀûÀÎ »ç°í, 213ÂÊ # def get_divisors(num): # numÀÇ ¾à¼ö¸¦ ÁýÇÕÇüÀ¸·Î ¹ÝȯÇÔ divisors = set() for i in range(2, num): if num % i == 0: divisors.add(i) return divisors x = 48 print(x, 'ÀÇ Áø¾à¼ö :', get_divisors(x)) y = 60 print(y, 'ÀÇ Áø¾à¼ö :', get_divisors(y)) | cs |