Submission #3353158

Source Code Expand

Copy
N, M = map(int, input().split())


def make_divisor_list(num, N):

    if num < 1:
        return 0
    elif num == 1:
        return 1
    else:
        max_num = 1
        for i in range(2, num // N + 1):
            if num % i == 0:
                # 割り切れる=約数
                if num / i >= N:
                    max_num = i
        return max_num

print(make_divisor_list(M, N))

Submission Info

Submission Time
Task D - Partition
User showyou41
Language Python3 (3.4.3)
Score 0
Code Size 414 Byte
Status

Test Cases

Set Name Score / Max Score Test Cases
All 0 / 400 0_small_1, 0_small_2, 0_small_3, 1_large_1, 1_large_2, 1_large_3, 1_large_4, 1_large_5, 1_large_6, 1_large_7, 2_max_1, 2_max_2, 3_prime_1, 3_prime_10, 3_prime_11, 3_prime_2, 3_prime_3, 3_prime_4, 3_prime_5, 3_prime_6, 3_prime_7, 3_prime_8, 3_prime_9, 4_hand_1, 4_hand_2, 4_hand_3, 4_hand_4, sample_01, sample_02, sample_03
Sample 0 / 0 sample_01, sample_02, sample_03
Case Name Status Exec Time Memory
0_small_1 17 ms 2940 KB
0_small_2 17 ms 2940 KB
0_small_3 20 ms 3188 KB
1_large_1 19 ms 3060 KB
1_large_2 33 ms 2940 KB
1_large_3 26 ms 2940 KB
1_large_4 17 ms 2940 KB
1_large_5 17 ms 3060 KB
1_large_6 17 ms 2940 KB
1_large_7 18 ms 2940 KB
2_max_1 18 ms 3064 KB
2_max_2 17 ms 3060 KB
3_prime_1 18 ms 2940 KB
3_prime_10
3_prime_11 17 ms 3060 KB
3_prime_2 18 ms 2940 KB
3_prime_3 18 ms 2940 KB
3_prime_4 17 ms 3060 KB
3_prime_5 17 ms 2940 KB
3_prime_6 17 ms 3060 KB
3_prime_7 17 ms 2940 KB
3_prime_8
3_prime_9
4_hand_1 18 ms 3060 KB
4_hand_2 17 ms 2940 KB
4_hand_3
4_hand_4 17 ms 3060 KB
sample_01 17 ms 3060 KB
sample_02 17 ms 2940 KB
sample_03 18 ms 3064 KB