Submission details
Task:Entrepreneur
Sender:aalto26aw_004
Submission time:2026-09-02 18:39:06 +0300
Language:Python3 (PyPy3)
Status:READY
Result:
Test results
testverdicttime
#10.04 sdetails
#20.04 sdetails
#30.04 sdetails
#40.04 sdetails
#50.00 sdetails
#60.05 sdetails
#70.04 sdetails
#80.09 sdetails
#90.12 sdetails
#100.17 sdetails
#110.04 sdetails
#120.04 sdetails
#13--details
#140.04 sdetails

Code

n, t = input().split()
n = int(n)
t = int(t)
k = input().split()
k = [int(a) for a in k]

l = 0
r = min(k) * t

while l < r:
    mid = int(l + (r - l) / 2)
    print(l, r, mid)
    cars = 0
    for m in k:
        cars += int(mid / m)
        if cars >= t:
            break

    if cars >= t:
        r = mid
    else:
        l = mid + 1

print(l)

Test details

Test 1

Verdict:

input
10 10
6 5 1 2 1 5 10 4 6 6

correct output
4

user output
0 10 5
0 5 2
3 5 4
3 4 3
4

Feedback: Output is longer than expected

Test 2

Verdict:

input
10 10
6 6 4 3 4 9 3 2 6 10

correct output
6

user output
0 20 10
0 10 5
6 10 8
6 8 7
6 7 6
...

Feedback: Output is longer than expected

Test 3

Verdict:

input
10 10
5 4 10 7 8 4 1 8 9 2

correct output
5

user output
0 10 5
0 5 2
3 5 4
5

Feedback: Output is longer than expected

Test 4

Verdict:

input
1 1000000000
1

correct output
1000000000

user output
0 1000000000 500000000
500000001 1000000000 750000000
750000001 1000000000 875000000
875000001 1000000000 937500000
937500001 1000000000 968750000
...

Feedback: Output is longer than expected

Test 5

Verdict:

input
1 1000000000
1000000000

correct output
1000000000000000000

user output
(empty)

Test 6

Verdict:

input
1000 1000
271 687 392 992 11 410 702 870...

correct output
223

user output
0 2000 1000
0 1000 500
0 500 250
0 250 125
126 250 188
...

Feedback: Output is longer than expected

Test 7

Verdict:

input
1000 1000
598 523 703 794 737 689 724 26...

correct output
282

user output
0 3000 1500
0 1500 750
0 750 375
0 375 187
188 375 281
...

Feedback: Output is longer than expected

Test 8

Verdict:

input
200000 1000000000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 ...

correct output
5000

user output
0 1000000000 500000000
0 500000000 250000000
0 250000000 125000000
0 125000000 62500000
0 62500000 31250000
...

Feedback: Output is longer than expected

Test 9

Verdict:

input
200000 1
760045594 599341056 300698860 ...

correct output
8214

user output
0 8214 4107
4108 8214 6161
6162 8214 7188
7189 8214 7701
7702 8214 7958
...

Feedback: Output is longer than expected

Test 10

Verdict:

input
200000 1000000000
33941840 210038922 596070148 7...

correct output
371045814100

user output
0 2754000000000 1377000000000
0 1377000000000 688500000000
0 688500000000 344250000000
344250000001 688500000000 5163...

Feedback: Output is longer than expected

Test 11

Verdict:

input
25 1000000000
1000000000 1 1 1 1 1 1 1 1 1 1...

correct output
41666667

user output
0 1000000000 500000000
0 500000000 250000000
0 250000000 125000000
0 125000000 62500000
0 62500000 31250000
...

Feedback: Output is longer than expected

Test 12

Verdict:

input
12 1000000000
1 1 1 1 1 1 1 1 1 1 1 10000000...

correct output
90909091

user output
0 1000000000 500000000
0 500000000 250000000
0 250000000 125000000
0 125000000 62500000
62500001 125000000 93750000
...

Feedback: Output is longer than expected

Test 13

Verdict:

input
23 1000000000
1000000000 1000000000 10000000...

correct output
43478261000000000

user output
(empty)

Test 14

Verdict:

input
3 3
10 11 12

correct output
12

user output
0 30 15
0 15 7
8 15 11
12 15 13
12 13 12
...

Feedback: Output is longer than expected