TnT/Multi_CodeNet4Repair huggingface dataset:
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
A, B, T = input().split(" ")
print(int(int(T)/int(A))*B)

A, B, T = input().split()
print(int(int(T)/int(A))*int(B))

Verdicts: Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
list(map(int, input().split()))

a, b, t = list(map(int, input().split()))
print(t // a * b)

Verdicts: Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
A = int(input())
B = int(input())
T = int(input())
x = T // A
y = B * x
print(y)

x = T % A
y = x * B
print(y)

A,B,T = map(int,input().split())
x = T // A
y = B * x
print(y)

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
a, b, t = map(int, input().split())

print((t+0.5)//a*b)

a, b, t = map(int, input().split())
 
print(int((t+0.5)//a*b))


Verdicts: Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
N = int(input())
A = list(map(int,input().split()))
A.sort()
D = [A[i+1]-A[i] for i in range(len(A)-1)]
 
if N == 2:
  print(max(A))
elif len(set(A))==1:
  print(A[0])
else:
  for d in D:
    cnt = 0
    for a in A:
      if a%d != 0:
        cnt = cnt+1
    if cnt <=1:
      print(i)
      break
    

A,B,T =  map(int,input().split())
print((T//A)*B)

Verdicts: Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
A, B, T = map(int, input().split())

print((T+0.5)//A*B)

A, B, T = map(int, input().split())
 
print(T // A * B)

Verdicts: Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
A,B,T=list(map(int,input().split()))
c=0
for i in range(1,T+1):
    if i%A==0:
        c+=1
        print(i)
print(c*B)

A,B,T=list(map(int,input().split()))
c=0
for i in range(1,T+1):
    if i%A==0:
        c+=1
print(c*B)

Verdicts: Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
A,B,T = map(int,input().split)

def main(A,B,T):
    time = A
    sum = 0
    while time <= T+0.5:
        if time%A == 0:
            sum += B
            time += 1
    print(sum)
    return 0


A,B,T = map(int,input().split())

def main(A,B,T):
    time = A
    sum = 0
    while time <= T+0.5:
        if time%A == 0:
            sum += B
            time += 1
    print(sum)
    return 0


def main(A,B,T):
    time = A
    sum = 0
    while time <= T+0.5:
        if time%A == 0:
            sum += B
            time += 1
    print(sum)
    return 0

 


def Biscuit_Generater(A,B,T):
    time = A
    sum = 0
    while time <= T+0.5:
        if time%A == 0:
            sum += B
            time += 1
    print(sum)
    return 0


import math
A,B,T = map(int,input().split())

def main(A,B,T):
    sum = B*(math.floor(T/A))
    print(sum)
    return 0

main(A,B,T)

Verdicts: Runtime Error

Wrong Answer

Wrong Answer

Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
A ,B ,T = map(int, input().split()) 
print(T/A*B)

A ,B ,T = map(int, input().split()) 
print((T//A)*B)

Verdicts: Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
#import math
from functools import reduce

def gcd(a,b):
    if b>a:
        a, b = b, a
    while b:
        a, b = b, a%b
    return a

def gcds(nums):
    return reduce(gcd, nums)

a = int(input())
a = [int(i) for i in input().split()]

ans = 0
for i in range(len(a)):
    aa = a[:i] + a[(i+1):]
    if ans < gcds(aa):
        ans = gcds(aa)
print(ans)

a, b, t = map(int, input().split())
ans = t // a * b
print(ans)

Verdicts: Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
a, b, t = map(int, input.split())
ans = 0
for i in range(a, t+1):
  ans += b
print(ans)

a, b, t = map(int, input().split())
ans = 0
for i in range(a, t+1):
  ans += b
print(ans)


a, b, t = map(int, input().split())
print(t//a*b)

Verdicts: Runtime Error

Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
def biscuit_generator(A: int, B: int, T: int)->int:
    return (A//T) * B


if __name__ == "__main__":
    A, B, T = map(int, input().split())
    ans = biscuit_generator(A, B, T)
    print(ans)


def biscuit_generator(A: int, B: int, T: int)->int:
    return (T//A) * B


if __name__ == "__main__":
    A, B, T = map(int, input().split())
    ans = biscuit_generator(A, B, T)
    print(ans)


Verdicts: Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
n = input()
print(n)

print("!!")

n = input()
args = n.split()

a = int(args[0])
b = int(args[1])
t = int(args[2])

c = int(t / a)

print(c * b)

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
a,b,t=map(int,input().split())
t+=0.5
print(t//a*b)

a,b,t=map(int,input().split())
t+=0.5
print(int(t//a*b))

Verdicts: Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
a, b, t = map(int, input().split())

print((t+0.5)//a * b)

a, b, t = map(int, input().split())

print(int((t+0.5)//a * b))

Verdicts: Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
A,B,T = map(int,input().split())
n = int((T + 0.5)//A)
print(n*A)

A,B,T = map(int,input().split())
n = int((T + 0.5)//A)
print(n*B)

Verdicts: Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
A,B,T=map(int,input().split())
T2=T+0.5
print(T2)
i=0
while i*A <= T2:
  i += 1
  
i=i-1
  
print(B*i)

A,B,T=map(int,input().split())
T2=T+0.5
i=0

while i*A <= T2:
  i += 1
  
i=i-1
  
print(B*i)

Verdicts: Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
A,B,T=(int(x) for x in input().split())
print(int(B*((T+0.5)/A)))

A,B,T=map(int,input().split())
print(B*(T+0.5)/A)

A,B,T=(int(x) for x in input().split())
print(int(B*(T+0.5)/A))

A,B,T=(int(x) for x in input().split())
print(int(B*int(((T+0.5)/A))))

Verdicts: Wrong Answer

Wrong Answer

Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
import copy

tmp = 0
Max = 1

N = int(input())

A_list = [int(i) for i in input().split()]
tmp_list = A_list

def operation(a,b):
    while a%b != 0:
        complete = a%b
        a = b
        b = complete
    return b

for i in range(N):
    
    tmp_list = copy.copy(A_list)
    del tmp_list[i] 
    #print(tmp_list)
        
    tmp = operation(tmp_list[0],tmp_list[1])
    
    for k in range(N-2):
        tmp = operation(tmp,tmp_list[k])
    
    if tmp > Max:
        Max = tmp

print(Max)

import copy

tmp = 0
Max = 1

N = int(input())

A_list = [int(i) for i in input().split()]
tmp_list = A_list

def operation(a,b):
    while a%b != 0:
        complete = a%b
        a = b
        b = complete
    return b

for i in range(N):
    
    tmp_list = copy.copy(A_list)
    del tmp_list[i] 
    #print(tmp_list)
        
    tmp = operation(tmp_list[0],tmp_list[1])
    
    for k in range(N-2):
        tmp = operation(tmp,tmp_list[k])
    
    if tmp > Max:
        Max = tmp

print(Max)

a,b,T = map(int, input().split())

ans = (T // a) *b

print(ans)

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
a,b,t = map(input,input().split())
ans = b*(t+0.5)//a
print(ans)


a,b,t = map(int,input().split())
ans = b*(t+0.5)//a
print(int(ans))

a,b,t = map(input,input().split())
ans = (t+0.5)*b/a
print(ans)

a,b,t = map(int,input().split())
ans = b*(t+0.5)//a
print(ans)


a,b,t = map(int,input().split())
print((t//a)*b)

Verdicts: Runtime Error

Wrong Answer

Runtime Error

Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
A, B, T = input.split(' ')
print(T / A * B)

A, B, T = input().split(' ')
A = int(A)
B = int(B)
T = int(T)
print(int(T / A) * B)

Verdicts: Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
A, B, T = map(int, input().split())
print(B*T//A)

A, B, T = map(int, input().split())
print(B * (T//A))

Verdicts: Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
a,b,t = map(int(input().split()))
n = int(t/a)
print(n*b)

a,b,t = map(int, input().split())
n = int(t/a)
print(n*b)

Verdicts: Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
a, b, t=map(int.input().split())
print(b*(t//a))

a, b, t=map(int, input().split())
print(b*(t//a))

Verdicts: Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
A, B, T = map(int, input().split())
print((T+0.5)//A*B)


a = list(map(int,input().split()))
A = a[0]
B = a[1]
T = a[2]
(T+0.5)//A*B

A,B,T=map(int,input().split())
print((T+0.5)//A*B)

a = list(map(int,input().split()))
A = a[0]
B = a[1]
T = a[2]
print((T+0.5)//A*B)

A,B,T=map(int,input().split())
(T+0.5)//A*B

a = list(map(int,input().split()))
A = a[0]
B = a[1]
T = a[2]
((T+0.5)//A)*B

a = list(map(int,input().split()))
A = a[0]
B = a[1]
T = a[2]
((T+0.5)//A)*B

A, B, T = map(int, input().split())
print(int(((T+0.5)//A*B)))

Verdicts: Wrong Answer

Wrong Answer

Wrong Answer

Wrong Answer

Wrong Answer

Wrong Answer

Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
print((T//A)*B)

A, B, T = map(int, raw_input().split())
print(int( (T+0.5)/A)*B)

return (T//A)*B

A, B, T = map(int, raw_input().split())
print(((T+0.5)//A)*B)

print((T//A)*B)

A, B, T = map(int, input().split())
print(int( (T+0.5)/A)*B)

Verdicts: Runtime Error

Runtime Error

Runtime Error

Runtime Error

Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
a,b,t=map(int,input().split())
cnt=0
for i in range(a,t,a):
  cnt=cnt+1
print(cnt)

a,b,t=map(int,input().split())
cnt=0
c=a
while a<=t :
  cnt+=b
  a+=c

print(cnt)

Verdicts: Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
def main():
    N = int(input())
    A = list(map(int, input().split()))

    if N == 2:
        print(max(A[0]+A[1], (-A[0])+(-A[1])))
        return

    a_sum, a1, a2 = 0, A[0], A[1]
    b_sum, b1, b2 = 0, -A[0], -A[1]

    for i in range(2, N):

        if (a_sum + a1 + a2 + A[i]) > (b_sum + b1 + b2 + A[i]):
            new_a_sum = a_sum + a1
            new_a1 = a2
            new_a2 = A[i]
        else:
            new_a_sum = b_sum + b1
            new_a1 = b2
            new_a2 = A[i]

        if (a_sum + a1 - a2 - A[i]) > (b_sum + b1 - b2 - A[i]):
            new_b_sum = a_sum + a1
            new_b1 = -a2
            new_b2 = -A[i]
        else:
            new_b_sum = b_sum + b1
            new_b1 = -b2
            new_b2 = -A[i]

        a_sum, a1, a2 = new_a_sum, new_a1, new_a2
        b_sum, b1, b2 = new_b_sum, new_b1, new_b2

    print(max(a_sum+a1+a2, b_sum+b1+b2))

main()

from fractions import gcd

def main():
    N = int(input())
    A = list(map(int, input().split()))

    if len(A) == 2:
        print(max(A))
        return

    if len(A) == 3:
        gcd1 = gcd(A[0], A[1])
        gcd2 = gcd(A[0], A[2])
        gcd3 = gcd(A[1], A[2])
        print(max(gcd1, gcd2, gcd3))
        return

    gcd1 = gcd(A[0], A[1])
    gcd2 = gcd(A[0], A[2])
    gcd3 = gcd(A[1], A[2])
    yet_used_gcd = max(gcd1, gcd2, gcd3)
    not_used_gcd = gcd(gcd1, A[2])

    for i in range(3, N):
        yet_used_gcd = gcd(yet_used_gcd, A[i])
        if yet_used_gcd < not_used_gcd:
            yet_used_gcd = not_used_gcd
        not_used_gcd = gcd(not_used_gcd, A[i])

    if yet_used_gcd > not_used_gcd:
        print(yet_used_gcd)
    else:
        print(not_used_gcd)

main()

a, b, t = map(int, input().split())

print((t // a)*b)


Verdicts: Runtime Error

Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
a,b,t=map(int,input().split())
print(((2t+1)//2a)*b)


a,b,t=map(int,input().split())
print(((2t+1)//(2*a))*b)


a,b,t=map(int,input().split())
print(((2t+1)//2*a)*b)


a,b,t=map(int,input().split())
print(((t+0.5)//a)*b)

a,b,t=map(int,input().split())
print(t//a*b)


Verdicts: Runtime Error

Runtime Error

Runtime Error

Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
def gcd(a, b):
    while True:
        bigger=max(a,b)
        smaller=min(a,b)
        mod=bigger%smaller
        if mod==0:
            return smaller
        else:
            return gcd(smaller, mod)

n = int(input())
a = list(map(int, input().split()))
ansers=[]
non_remove=a[0]
ansers.append(a[1])
for i in range(1, n):
    ansers = [ gcd(ans, a[i]) for ans in ansers ]
    ansers.append(non_remove)
    non_remove = gcd(non_remove, a[i])
print(max(ansers))

a, b, t = map(int, input().split())
print(t//a*b)

Verdicts: Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
import numpy as np

a, b, t = (int(i) for i in input().split())  

print(t //(a*3)* b)

a, b, t = (int(i) for i in input().split())  
print(int(t/(a*3))* b)

import numpy as np

N = int(input())
A = [int(i) for i in input().split()] 
Acnt = 0
for i in range(N):
	if A[i] < 0:
		Acnt += 1
res = np.sum(np.abs(A)) - np.min(np.abs(A))*2
print(res)


a, b, t = (int(i) for i in input().split())  
print(int(t/a* b)

a, b, t = (int(i) for i in input().split())  
print(int(t/a)* b)

Verdicts: Wrong Answer

Wrong Answer

Runtime Error

Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
A, B, T= map(int, input().split())
T = T + 0.5
B_max = 0
for i in range(20):
  if T > i*A:
    B_max += B
  else:
    break

print(B_max)
    

A, B, T= map(int, input().split())
T = T + 0.5
B_max = 0
for i in range(1,21):
  if T > i*A:
    B_max += B
  else:
    break
 
print(B_max)

Verdicts: Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
def gcd(a,b):
    while b != 0:
        a,b=b,a%b
    return a

n=int(input())
a=[0] + list(map(int,input().split())) + [0]

l=[0]*(n+2)
r=[0]*(n+2)
for i in range(1,n+1):
    l[i] = gcd(l[i-1],a[i])
for i in range(n,0,-1):
    r[i] = gcd(r[i+1],a[i])

z=[gcd(l[i-1],r[i+1]) for i in range(1,n+1)]

print(max(z))


a,b,t = map(int,input().split())
print(b*(t//a))


Verdicts: Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
a,b,t = map(int, input().split())
print(b*a//t)

a,b,t = map(int, input().split())
print(b*(a//t))

a,b,t = map(int, input().split())
print(b*(t//a))

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
import functools
import math
N = int(input())
A = [int(i) for i in input().split()]
num = 1
for i in range(len(A)):
  B = A[:i] + A[i+1:]
  g = functools.reduce(math.gcd, B)
  if g > num:
    num = g    
print(num)


import functools
import fractions

N = int(input())
A = [int(i) for i in input().split()]

num = 1

if len(A) == 2:
  print(max(A))
else:
  for i in range(len(A)):
    g = functools.reduce(fractions.gcd, A[:i] + A[i+1:])
    num = g if g > num else num
  print(num)


a, b, t = map(int, input().split())

n = t // a
print(n * b)

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
import math
A, B, T = map(int, input().split())

print(int(math.floor(T / A) + B))

import math
A, B, T = map(int, input().split())

print(int(math.floor(T / A) * B))

Verdicts: Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
k = (int(t) + 0.5) // int(a)
i = int(k) * int(b)
print(i)


a,b,t = (int(i) for i in input().split())
print(t//a*b)

Verdicts: Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
import fractions
from functools import reduce
import random
import copy

def gcd(numbers):
    return reduce(fractions.gcd, numbers)

n = int(input())
a = list(map(int, input().split()))
ans = 1

if n < 100:
  for i in range(n):
    b = copy.copy(a)
    b.pop(i)
    t = gcd(b)
    if ans < t:
      ans = t
else:
  for _ in range(100):
    t = gcd(random.sample(a, 30))
    if ans < t:
      ans = t

print(ans)

import fractions
from functools import reduce
import random
import copy

def gcd(numbers):
    return reduce(fractions.gcd, numbers)

n = int(input())
a = list(map(int, input().split()))
ans = 1

if n < 100:
  for i in range(n):
    b = copy.copy(a)
    b.pop(i)
    t = gcd(b)
    if ans < t:
      ans = t
else:
  for _ in range(100):
    t = gcd(random.sample(a, 50))
    if ans < t:
      ans = t

print(ans)


a, b, t = map(int, input().split())

ans = (t // a) * b

print(ans)

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
import copy

def gcd(a, b):
    while b != 0:
        a, b = b, a%b
    return a

def gcd_list(numbers):
    g = numbers[0]
    for m in numbers:
        g = gcd(g, m)
    return g

N = int(input())
A = list(map(int, input().split(" ")))

gcds = list()
for a in A:
    B = copy.deepcopy(A)
    B.remove(a)
    g = gcd_list(B)
    gcds.append(g)
print(max(gcds))

input_str = input().split(" ")
input_int = list(map(int, input_str))
A = input_int[0]
B = input_int[1]
T = input_int[2]

bis_sum = 0
start = 0
end = A
while True:
    if start < T+0.5 and end > T+0.5:
        break
    start += A
    end += A
    bis_sum += B

print(bis_sum)

Verdicts: Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
# coding: utf-8
# Your code here!
a,b,t=map(int,input().split(" "))
t+=0.5
ans=0
if(t>a):
    ans=(t-t%a)/a*b
print(ans)

# coding: utf-8
# Your code here!
a,b,t=map(int,input().split(" "))
t+=0.5
ans=0
if(t>a):
    ans=(t-t%a)/a*b
print(round(ans))

Verdicts: Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
import copy
import functools
import math

N = int(input())
A = sorted(list(map(int,input().split())))

C = []
for k in range(N):
    B = copy.copy(A)
    del B[k]
    C.append(functools.reduce(math.gcd, B))

print(max(C))

A, B, T = map(int,input().split())

ans = T // A * B

print(ans)

Verdicts: Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
from collections import*
def dv(n):
    divisors = []
    for i in range(1, int(n**0.5)+1):
        if n % i == 0:
            divisors.append(i)
            if i != n // i:
                divisors.append(n//i)
 
    
    return Counter(divisors)
 
n,*a=map(int,open(0).read().split())
ans=Counter()
for i in range(n):
    ans+=dv(a[i])
l=[]
for k,v in ans.items():
    if v==n-1 or v==n:
        l.append(k)
print(max(l))

from itertools import*
from fractions import*
n,*a=map(int,open(0).read().split())
b=list(accumulate([0]+a,gcd))
c=list(accumulate([0]+a[::-1],gcd))
print(max(gcd(s,t)for s,t in zip(b,c[::-1][1:])))

a,b,t=map(int,input().split());print(int(t//a*b))


Verdicts: Runtime Error

Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
A,B,T = map(int, input().split())

i = 1
count = 0
while A*i <= (T+0.5):
  count += i * T
  
print(count)

A,B,T = map(int, input().split())

i = 1
count = 0
while A*i <= (T+0.5):
  count += i * B
  i += 1
  
print(count)

A,B,T = map(int, input().split())

i = 1
count = 0
while A*i <= (T+0.5):
  count += i * T
  i += 1
  
print(count)

A,B,T = map(int, input().split())

i = 1
count = 0
while A*i <= (T+0.5):
  count += B
  i += 1
  
print(count)

Verdicts: Time Limit Exceeded

Wrong Answer

Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
a,b,t = map(input().split())
r = b * int(t/a)
print(r)

a,b,t=map(int,input ().split())
r=b*(t/a)
print(r)


a,b,t = map(int,input().split())
r = b * int(t/a)
print(r)

Verdicts: Runtime Error

Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
from fractions import *
n = int(input())
a = [0]+list(map(int, input().split()))+[0]
b = [0]*(n+2)
c = [0]*(n+2)
for i in range(1, n+1):
	b[i] = gcd(b[i-1], a[i])
for i in range(n, 0, -1):
	c[i] = gcd(c[i+1], a[i])
print(max(gcd(b[i-1], c[i+1]) for i in range(1, n+1)))
#sample answer.

a,b,t=map(int,input().split())
print(a//t*b)

a,b,t=map(int,input().split())
print(t//a*b)


Verdicts: Runtime Error

Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
a,b,t = map(int, input().split())
 
print(int((t+0.5)/a*b))

a,b,t = map(int, input())

print(int((t+0.5)/a*b))

a,b,t = map(int, input())
 
print(t//a*b)

a,b,t = map(int, input().split())
 
print((t//a)*b)

Verdicts: Wrong Answer

Runtime Error

Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
a, b, t = [int(x) for x in input().split()]
sum = b*(t+0.5)//a
print(sum)

a, b, t = [int(x) for x in input().split()]
sum = int(b*((t+0.5)//a))
print(sum)

Verdicts: Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
i=list(map(int,input().split()))
a=i[2]+0.5
b=a//i[0]
print(b*i[1])

i=list(map(int,input().split()))
a=i[2]+0.5
b=a//i[0]
c=b*i[1]
print(c)

i=list(map(int,input().split()))
a=i[2]+0.5
b=a//i[0]
c=b*i[1]
d=int(c)
print(d)

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
a,b,t = map(int,input().split())

print(a*((t+0.5)//b))

a,b,t = map(int,input().split())
 
print(int(b*((t+0.5)//a)))

Verdicts: Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
a,b,t=map(int,input().split())
print((t/a)*b)


a,b,c=map(int,input().split())
print(c//a*b)

Verdicts: Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
A,B,T=map(int,input())

print(B*(T//A))


N=int(input())

V=list(map(int,input().split()))
C=list(map(int,input().split()))

ans=0
for i in range(N):
	if(V[i]-C[i]>0):
		ans+=V[i]-C[i]
print(ans)


A,B,T=map(int,input().split())

print(B*(T//A))


Verdicts: Runtime Error

Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
import sys
a,b,t = list(map(int, input().split()))
print(b*(c//a))

import sys
a,b,t = list(map(int, input().split()))
print(b*(t//a))

Verdicts: Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
print(int(((T+0.5)//A)*B))

A,B,T = map(int,input().split)
print(int(((T+0.5)//A)*B))

A,B,T = map(int,input().split())
print(int(((T+0.5)//A)*B))


Verdicts: Runtime Error

Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
N = int(input())
A = list(map(int,input().split()))


for i in range(max(A),1,-1):
    l = list(map(lambda x: x % i,A))
    if l.count(0) >= len(A)-1:
        print(i)
        break


from functools import reduce
import math

N = int(input())
A = list(map(int,input().split()))

gcd = []

for i in range(len(A)):
    B = A[i]
    A.pop(i)
    gcd.extend([reduce(math.gcd,A)])
    A.insert(i,B)

print(max(gcd))


N = int(input())
A = list(map(int,input().split()))
A.sort()

w_min = A[1]

for i in range(w_min,0,-1):
    count = 0
    for j in A:
        if j%i != 0:
            count = count + 1
            if count > 1:
                break
    if count < 2:
        print(i)
        break
    


A,B,T = map(int,input().split())

print(T//A * B)


Verdicts: Runtime Error

Runtime Error

Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
from copy import copy
def gcd(a, b):
	if a%b == 0:
		return b
	else:
		return gcd(b, a%b)

n = int(input())
a = list(map(int, input().split()))

if n==2:
	print(max(a))
	quit()

gcds = []


for i in range(n):
	temp = copy(a)
	temp.pop(i)

	num1 = temp[0] 
	num2 = temp[1] 
	result = gcd(num1, num2) 
  
	for j in range(2, len(temp)): 
		if result in gcds:
			break
		result = gcd(result, temp[j]) 

	if result not in gcds:
		gcds.append(result)
      
if len(gcds)==1:
	print(gcds[0])
else:
	gcds = sorted(gcds)
	print(gcds[1])

a, b, t = map(int, input().split())

num = t//a

print(b*num)

Verdicts: Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
num = int(input())
V = list(input().split(" "))
C = list(input().split(" "))
result = 0

for i in range(num):
    Vi = int(V[i])
    Ci = int(C[i])
    if Vi <= Ci:
        continue
    result += (Vi - Ci )

print(result)


A,B,T = map(int,input().split(" "))

num = int(T/A)

print(num*B)


Verdicts: Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
# -*- coding: utf-8 -*-

# C - GCD on Blackboard








#     if a == b:
#         return a
#     else:



def gcd(x, y):
    while x != y:
        x, y = (x-y,y) if x>y else (y-x,x)
    return x
        


def calc(n, an):
    if n == 2:
        return gcd(an[0], an[1])
    else:
        return gcd(an[0], calc(n-1, an[1:]))


n = int(input())
an = [int(x) for x in input().split(' ')]

if n == 2:
    print(max(an))
else:
    
    
    bn = [[an[j] for j in range(n) if i != j] for i in range(n)]
    gcds = [calc(n-1, ary) for ary in bn]
    print(max(gcds))



def gcd(x, y):
    
    a, b = (x,y) if x>y else (y,x)
    if a == b:
        return a
    else:
        return gcd(a-b,b)


def calc(n, an):
    if n == 2:
        return gcd(an[0], an[1])
    else:
        return gcd(an[0], calc(n-1, an[1:]))


n = int(input())
an = [int(x) for x in input().split(' ')]

if n == 2:
    print(max(an))
else:
    
    
    bn = [[an[j] for j in range(n) if i != j] for i in range(n)]
    gcds = [calc(n-1, ary) for ary in bn]
    print(max(gcds))

# -*- coding: utf-8 -*-

# C - GCD on Blackboard





def gcd(x, y):
    
    a, b = (x,y) if x>y else (y,x)
    if a == b:
        return a
    else:
        return gcd(a-b,b)


def calc(n, an):
    if n == 2:
        return gcd(an[0], an[1])
    else:
        return gcd(an[0], calc(n-1, an[1:]))


n = int(input())
an = [int(x) for x in input().split(' ')]

if n == 2:
    print(max(an))
else:
    
    
    bn = [[j for j in an if i != j] for i in an]
    if len(bn) == 0:
        print(an[0])
    else:
        gcds = [calc(n-1, ary) for ary in bn]
        print(max(gcds))

# -*- coding: utf-8 -*-
A = int(input())
if A < 1:
    print('×')
else:
    B = int(input())
    if B < 0:
        print('×')
    else:    
        T = int(input())
        if T < 0 and T > 20:
            print('×')
        else:                    
            T+=0.5
            ans = (T // A) *B
            print(ans)




'''
Result: All Correct
Score: 100
Code length: 91 Byte
Execution Time: 17 ms
Memory usage: 2940 KB
'''

hoge = input()
a, b, t = [int(x) for x in hoge.split(' ')]
print(int(((t+0.5)//a)*b))

Verdicts: Runtime Error

Runtime Error

Runtime Error

Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
n = int(input())
a = list(map(int,input().split()))
pal =1
minabs = 10**9
for i in range(n):
    if a[i] <0:
        pal *=-1
        a[i] = -1*a[i]
    minabs = min(minabs,a[i])
if pal ==1:
    print(sum(a))
else:
    print(sum(a)-2*minabs)


a,b,t = map(int,input().split())
s = t//a
print(b*s)


Verdicts: Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):

def problem():
    A, B, T = map(int, input().split())
    algorithm(A, B, T)


def algorithm(A: int, B: int, T: int):
    x = int((T + 0.5) / A)
    return x*B

problem()



def problem():
    A, B, T = map(int, input().split())
    print(algorithm(A, B, T))


def algorithm(A: int, B: int, T: int):
    x = int((T + 0.5) / A)
    return x*B



problem()

Verdicts: Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
a, b, t = map(int, input().split())

print((t + 0.5) // a * b)



a, b, t = map(int, input().split())

print((t // a) * b)



Verdicts: Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
A, B, T = map(int, input().split())
print(B * ((T + 0.5) // A))

A, B, T = map(int, input().split())
print(B * (T // A))


Verdicts: Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
A,B,T=map(int,input().split())
print(((T+0.5)//A)*B)

A,B,T=map(int,input().split())
print(int(((T+0.5)//A)*B))

Verdicts: Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
print(0)

# coding: utf-8
# Your code here!

A, B, T = map(int, input().split())

# print(A)

# print(T)

print(int(T / A) * B)

Verdicts: Wrong Answer

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
A, B, T = map(int, input().split())
int sum = 0
int t = 0
while(t <= T):
  if t%A == 0:
    sum += B
  t += 1
print(sum)


A, B, T = map(int, input().split())
int sum = 0
int t = 0
while(t < T+0.5):
  if t%A == 0:
    sum += B
  t += 1
print(sum)

A, B, T = map(int, input().split())
cnt = T // A
ans = B * cnt
print(ans)


Verdicts: Runtime Error

Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
A, B, T = map(int, input())
print((T // A) * B)

A, B, T = map(int, input().split())
print((T // A) * B)


Verdicts: Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
N = int(input())
A = list(map(int, input().split()))

souwa = 0
cnt = 0
keep = 1e10

for i in range(N):
    if A[i] < 0:
        cnt += 1
        A[i] *= (-1)

    souwa += A[i]
    keep = min(keep, A[i])

print(souwa - 2 * keep * (cnt % 2))


A,B,T=map(int,input().split())
i=0
while A*i<=T:
    i=i+1
print(B*(i-1))

Verdicts: Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
# -*- coding: utf-8 -*-
import fractions
import copy
from functools import reduce

def gcd_list(numbers):
    return reduce(fractions.gcd, numbers)

N = int(input())
A = list(map(int, str(input()).split()))

gcds = list()
for i in range(0,N):
    B = copy.deepcopy(A)
    B.pop(i)
    tmp = gcd_list(B)
    gcds.append(tmp)

print(max(gcds))


# -*- coding: utf-8 -*-
A = list(map(int,input().split()))
print(A[2] // A[0] * A[1])

Verdicts: Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
A, B, T = map(int, input().split())

def biscuit_gen(A,B,T):
    total = 0
    num = int(T//A)
    return B*num

print(biscuit_gen(A,B,t))

A, B, T = map(int, input().split())

def biscuit_gen(A,B,T):
    total = 0
    num = int(T//A)
    return B*num

n = biscuit_gen(A,B,T)
print(n)

Verdicts: Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
import itertools
import numpy as np
import fractions
from functools import reduce

N = int(input())
A = np.array(input().split()).astype(int)

def gcd(numbers):
    return reduce(fractions.gcd, numbers)
rt = 1
for i in range(N):
    ind = np.ones(N, dtype=bool)
    ind[i]=False
    A_tmp = A[ind]
    f = gcd(A_tmp)
    if rt < f:
        rt = f
print(rt)


A, B, T = map(int, input().split())
print((T//A)*B)

Verdicts: Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
N = int(input())
A = [int(x) for x in input().split(' ')]

s = 0
mc = 0
for i in A:
  if i <= 0:
    mc += 1
  s += abs(i)

if (mc % 2 == 1):
  mv = min(A[0],A[-1])
  #print('mv',mv)
  s -= mv*2
print(s)

A,B,T = [int(x) for x in input().split(' ')]
print(int(B * ((T + 0.5) // A)))


Verdicts: Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
def gcd(a, b):
    while b != 0:
        a, b = b, a % b
    return a


N = int(input())
A = list(map(int, input().split()))
L = [0 for i in range(N)]
R = [0 for i in range(N)]
T = [0 for i in range(N)]

for i in range(N):
    if i == 0:
        L[i] = 0
    else:
        L[i] = gcd(L[i-1], A[i-1])
for i in range(N-1, 0, -1):
    if i == N-1:
        R[i] = 0
    else:
        R[i] = gcd(R[i+1], A[i+1])
for i in range(N):
    T[i] = gcd(L[i], R[i])

print(max(T))

I = list(map(int, input().split()))
A = I[0]
B = I[1]
T = I[2]

ans = (T // A) * B

print(ans)


Verdicts: Runtime Error

Accepted
Problem: A biscuit making machine produces B biscuits at the following moments: A seconds, 2A seconds, 3A seconds and each subsequent multiple of A seconds after activation.  Find the total number of biscuits produced within T + 0.5 seconds after activation.

Submission attempts (in order):
a,b,t=map(int,input(),split())
print(((t+1/2)//a)*b)


a,b,t=map(int,input().split())
print(((t+1/2)//a)*b)


a,b,t=map(int,input().split())
print(((t+1//2)//a)*b)


Verdicts: Runtime Error

Wrong Answer

Accepted