Problem:


Score : 100 points

Problem Statement

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.

Constraints

All values in input are integers.

1 \leq A, B, T \leq 20

Input

Input is given from Standard Input in the following format:

A B T

Output

Print the total number of biscuits produced within T + 0.5 seconds after activation.

Sample Input 1

3 5 7

Sample Output 1

10

Five biscuits will be produced three seconds after activation.

Another five biscuits will be produced six seconds after activation.

Thus, a total of ten biscuits will be produced within 7.5 seconds after activation.

Sample Input 2

3 2 9

Sample Output 2

6

Sample Input 3

20 20 19

Sample Output 3

0



Sample input:
3 5 7


Sample output:
10

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
import sys
INF = float("inf")


def solve(A: int, B: int, T: int):
    print(B*int(T/A))
    return


def main():

    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    A = int(next(tokens))  # type: int
    B = int(next(tokens))  # type: int
    T = int(next(tokens))  # type: int
    solve(A, B, T)


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
A, B, T = [int(_) for _ in input().split()]

result = T // A * B

print(result)

Submission status: Accepted

Solution code:
A,B,C = map(int,input().split(" "))
print((C//A)*B)

Submission status: Accepted

Solution code:
a,b,c = map(int,input().split())
print(int((c+0.5)//a*b))

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys
stdin = sys.stdin
 
ni = lambda: int(ns())
na = lambda: list(map(int, stdin.readline().split()))
nn = lambda: list(stdin.readline().split())
ns = lambda: stdin.readline().rstrip()

a,b,t = na()

print(t//a*b)

Submission status: Accepted

Solution code:
#A問題
A,B,T=map(int,input().split())
print(B*int(T/A))

Submission status: Accepted

Solution code:
a,b,c=list(map(int, input().split()))
print(c//a*b)

Submission status: Accepted

Solution code:
#!/usr/bin/env python

from collections import deque
import itertools as it
import sys
import math

sys.setrecursionlimit(1000000)

INF = 10 ** 18
MOD = 10 ** 9 + 7

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

Submission status: Accepted

Solution code:
import sys,collections as cl
Max = sys.maxsize
def l():
	return list(map(int,input.split()))
def m():
	return map(int,input().split())
def s(x):
	a = []
	aa = x[i]
	su = 1
	for i in range(len(x)-1):
		if aa == x[i+1]:
			a.append([aa,su])
			aa = x[i+1]
			su = 1
		else:
			su += 1
	a.append([aa,su])
	return a

a,b,t = m()

print((t//a) * b)

Submission status: Accepted

Solution code:
A, B, T = list(map(int, input().split()))

print(T // A * B)

Submission status: Accepted

Solution code:
A, B, T = list(map(int, input().split()))

ans = T//A * B
print(ans)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
[a,b,t] = [int(i) for i in input().split()]
print(int(t/a) * b)

Submission status: Accepted

Solution code:
# python template for atcoder1
import sys
sys.setrecursionlimit(10**9)
input = sys.stdin.readline

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

Submission status: Accepted

Solution code:
A, B, T = map(int, input().split())
ans = 0
for i in range(1, T+1):
    if i % A == 0:
        ans += B
print(ans)

Submission status: Accepted

Solution code:
A,B,T=map(int,input().split(' '))
print((T//A)*B)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
A, B, T = [int(i) for i in input().split()]
print((T // A) * B)

Submission status: Accepted

Solution code:
import collections as c
ip = lambda : map(int, input().split())

#################
a,b,t = ip()
print(t//a*b)

Submission status: Accepted

Solution code:
def gcd_core(a, b):
    if b == 0:
        return a
    else:
        return gcd_core(b, a % b)


def gcd(arr):
    g = gcd_core(arr[0], arr[1])
    for i in range(2, len(arr)):
        g = gcd_core(g, arr[i])
    return g

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

print(b*(t//a))

Submission status: Accepted

Solution code:
import sys
sys.setrecursionlimit(10**7)
INF = 10 ** 18
MOD = 10 ** 9 + 7
def LI(): return [int(x) for x in sys.stdin.readline().split()]
def LI_(): return [int(x) - 1 for x in sys.stdin.readline().split()]
def LF(): return [float(x) for x in sys.stdin.readline().split()]
def LS(): return sys.stdin.readline().split()
def II(): return int(sys.stdin.readline())
def SI(): return input()

def main():
    A, B, T = LI()
    ans = (T // A) * B
    return ans

print(main())

Submission status: Accepted

Solution code:
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians
from itertools import permutations, combinations, product
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits

def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
MOD = 10 ** 9 + 7

A, B, T = MAP()

print(T//A * B)

Submission status: Accepted

Solution code:
def main():
	A, B, T = map(int,input().split())
	print((T//A)*B)

if __name__ == '__main__':
    main()

Submission status: Accepted

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

print(int(T//A)*B)

Submission status: Accepted

Solution code:
import math,string,itertools,fractions,heapq,collections,re,array,bisect,sys,copy,functools
import random

sys.setrecursionlimit(10**7)
inf = 10**20
eps = 1.0 / 10**10
mod = 998244353
dd = [(-1,0),(0,1),(1,0),(0,-1)]
ddn = [(-1,0),(-1,1),(0,1),(1,1),(1,0),(1,-1),(0,-1),(-1,-1)]

def LI(): return list(map(int, sys.stdin.readline().split()))
def LI_(): return [int(x)-1 for x in sys.stdin.readline().split()]
def LF(): return [float(x) for x in sys.stdin.readline().split()]
def LS(): return sys.stdin.readline().split()
def I(): return int(sys.stdin.readline())
def F(): return float(sys.stdin.readline())
def S(): return input()
def pf(s): return print(s, flush=True)


def main():
    a,b,t = LI()

    return t // a * b


print(main())

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys
import math
import collections
import itertools
import array
import inspect

# Set max recursion limit
sys.setrecursionlimit(1000000)


# Debug output
def chkprint(*args):
    names = {
        id(v): k
        for k, v in inspect.currentframe().f_back.f_locals.items()
    }
    print(', '.join(
        names.get(id(arg), '???') + ' = ' + repr(arg) for arg in args))


# Binary converter
def to_bin(x):
    return bin(x)[2:]


def li_input():
    return [int(_) for _ in sys.stdin.readline().split()]


def gcd(n, m):
    if n % m == 0:
        return m
    else:
        return gcd(m, n % m)


def gcd_list(L):
    v = L[0]

    for i in range(1, len(L)):
        v = gcd(v, L[i])

    return v


def lcm(n, m):
    return (n * m) // gcd(n, m)


def lcm_list(L):
    v = L[0]

    for i in range(1, len(L)):
        v = lcm(v, L[i])

    return v

def comb(n, r):
    if n - r < r: r = n - r
    if r == 0: return 1
    if r == 1: return n

    numerator = [n - r + k + 1 for k in range(r)]
    denominator = [k + 1 for k in range(r)]

    for p in range(2, r + 1):
        pivot = denominator[p - 1]
        if pivot > 1:
            offset = (n - r) % p
            for k in range(p - 1, r, p):
                numerator[k - offset] /= pivot
                denominator[k] /= pivot

    result = 1
    for k in range(r):
        if numerator[k] > 1:
            result *= int(numerator[k])

    return result

def bisearch(L, target):
    low = 0
    high = len(L) - 1
    
    while low <= high:
        mid = (low + high) // 2
        guess = L[mid]
        if guess == target:
            return True
        elif guess < target:
            low = mid + 1
        elif guess > target:
            high = mid - 1
    if guess != target:
        return False

# --------------------------------------------

dp = None


def main():
    A, B, T = li_input()
    print((T // A) * B)


main()

Submission status: Accepted

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

print(ans)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
#!usr/bin/env python3
from collections import defaultdict
from collections import deque
from heapq import heappush, heappop
import sys
import math
import bisect
import random
def LI(): return list(map(int, sys.stdin.readline().split()))
def I(): return int(sys.stdin.readline())
def LS():return list(map(list, sys.stdin.readline().split()))
def S(): return list(sys.stdin.readline())[:-1]
def IR(n):
    l = [None for i in range(n)]
    for i in range(n):l[i] = I()
    return l
def LIR(n):
    l = [None for i in range(n)]
    for i in range(n):l[i] = LI()
    return l
def SR(n):
    l = [None for i in range(n)]
    for i in range(n):l[i] = S()
    return l
def LSR(n):
    l = [None for i in range(n)]
    for i in range(n):l[i] = LS()
    return l
sys.setrecursionlimit(1000000)
mod = 1000000007

#A
def A():
    a,b,t = LI()
    k = t//a
    print(k*b)
    return

#B
def B():
    n = I()
    return

#C
def C():
    n = I()
    return

#D
def D():
    n = I()
    return


#Solve
if __name__ == "__main__":
    A()

Submission status: Accepted

Solution code:
import sys
import math

sys.setrecursionlimit(10000)
INF = float('inf')


def inp():
    return int(input())


def inl():
    return list(map(int, input().split()))


def inls():
    return input().split()


def Yesif(cond):
    print('Yes' if cond else 'No')


def YESIF(cond):
    print('YES' if cond else 'NO')


def yesif(cond):
    print('yes' if cond else 'no')



a, b, t = inl()
print(t // a * b)

Submission status: Accepted

Solution code:
A,B,T=[int(x) for x in input().split()]
print(int(T/A)*B)

Submission status: Runtime Error

Solution code:
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))

Submission status: Runtime Error

Solution code:
a, b, t = map(int, input().split())
print(t//a*b)
debug_pri

Submission status: Runtime Error

Solution code:
n = int(input())
A = list(map(int, input().split()))
cnt = 0
s = 0
m = 10 ** 9
for ai in A:
    if ai <= 0:
        cnt = cnt + 1
        ai *= (-1)
    s += ai
    if m > ai:
        m = ai
if cnt % 2 == 0:
    for a in A:
        ans = s
else:
    ans = s - 2*m
print(ans)

Submission status: Runtime Error

Solution code:
using System;
using System.Runtime.InteropServices;

namespace ConsoleApp2
{
    class Program
    {
        static void Main(string[] args)
        {
            int a, b, t;
            string[] str =Console.ReadLine().Split(' ');
            a = int.Parse(str[0]);
            b = int.Parse(str[1]);
            t = int.Parse(str[2]);
            Console.WriteLine(b * (t / a));
        }
    }
}

Submission status: Runtime Error

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

Submission status: Runtime Error

Solution code:
A,B,T = map(input().split())
print(T//A*B)

Submission status: Runtime Error

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

Submission status: Runtime Error

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

A_tmp = sorted(A, key=abs, reverse=True,)
total = 0
for i,v in enumerate(A_tmp):
    if (v <= 0) and (i < len(A_tmp)-1):
        v *= (-1)
        A_tmp[i+1] = (-1) * A_tmp[i+1]
    total += v
print(total)

Submission status: Runtime Error

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

A_tmp = sorted(A, key=abs, reverse=True,)
total = 0
for i,v in enumerate(A_tmp):
    if (v <= 0) and (i < len(A_tmp)-1):
        A_tmp[i+1] = (-1) * A_tmp[i+1]
    total += abs(v)
print(total)

Submission status: Runtime Error

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

Submission status: Runtime Error

Solution code:
from collections import defaultdict,deque
import math
def gcd(a,b):
    return b if not a%b else gcd(b,a%b)
def lcm(a,b):
    return (a*b)//gcd(a,b)

def main():
    n = int(input())
    A=[int(i) for i in input().split()]
    res = 0
    m = 0
    for i in range(n):
        l_m = A[0]
        r_m = A[n-1]
        if(i!=0 and i!=n-1):
            for j in range(1,i):
                l_m = gcd(l_m,A[j])

            for j in range(n-1,i,-1):
                r_m = gcd(r_m,A[j])
            res = max(res,gcd(l_m,r_m))
        else:
            if(i==0):
                for j in range(1,n-1):
                    r_m = gcd(r_m,A[j])
                res = max(res,r_m)
            else:
                for j in range(1,n-1):
                    l_m = gcd(l_m,A[j])
                res = max(res,l_m)
    print(res)


if __name__ == '__main__':
    main()

Submission status: Runtime Error

Solution code:
n = input().split()
ans = int( int(n[2]+0.5) / n[1]   ) * n[1]
print(ans)

Submission status: Runtime Error

Solution code:
n = input().split()
print(int((n[2] + 0.5 ) / n[0]) * n[1])

Submission status: Runtime Error

Solution code:
def main():
    a,b,t = map(int,input().split())
    ans = 0
    for i in range(t + 0.51, 1):
        if i % a == 0:
            ans += b
    print(ans)
main()

Submission status: Runtime Error

Solution code:
def main():
    a,b,t = map(int,input().split())
    ans = 0
    for i in (t + 1):
        if i % a == 0:
            ans += b
    print(ans)
main()

Submission status: Runtime Error

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

print(b*(a//t))

Submission status: Runtime Error

Solution code:
a,b,t = map(int,input().split())
ans = 0
T = A
while(T<=t):
  ans += B
  T += A
print(ans)

Submission status: Runtime Error

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

Submission status: Runtime Error

Solution code:
import sys
sys.setrecursionlimit(10**8)
def ii(): return int(sys.stdin.readline())
def mi(): return map(int, sys.stdin.readline().split())
def li(): return list(map(int, sys.stdin.readline().split()))
def li2(N): return [list(map(int, sys.stdin.readline().split())) for _ in range(N)]
def dp2(ini, i, j): return [[ini]*i for _ in range(j)]
#import bisect #bisect.bisect_left(B, a)
#from collections import defaultdict #d = defaultdict(int) d[key] += value
#from collections import Counter # a = Counter(A).most_common()
#from itertools import accumulate #list(accumulate(A))
from functools import reduce

def segfunc(a,b):
    if a == 0 or b == 0:
        return max(a, b)
    if a < b:
        a, b = b, a
    r = a % b
    if r == 0:
        return b
    return segfunc(b, r)

def gcd_list(numbers):
    return reduce(segfunc, numbers)

def init(init_val):
    #set_val
    for i in range(n):
        seg[i+num-1]=init_val[i]    
    #built
    for i in range(num-2,-1,-1) :
        seg[i]=segfunc(seg[2*i+1],seg[2*i+2]) 
    
def update(k,x):
    k += num-1
    seg[k] = x
    while k:
        k = (k-1)//2
        seg[k] = segfunc(seg[k*2+1],seg[k*2+2])
    
def query(p,q):
    if q<=p:
        return ide_ele
    p += num-1
    q += num-2
    res=ide_ele
    while q-p>1:
        if p&1 == 0:
            res = segfunc(res,seg[p])
        if q&1 == 1:
            res = segfunc(res,seg[q])
            q -= 1
        p = p//2
        q = (q-1)//2
    if p == q:
        res = segfunc(res,seg[p])
    else:
        res = segfunc(segfunc(res,seg[p]),seg[q])
    return res


n = ii()
#A = sorted(li())
A = li()

#####単位元######
'''
if n == 2:
    print(max(A))
    exit()
elif n == 3:
    ide_ele = max(segfunc(A[0], A[1]), segfunc(A[1], A[2]), segfunc(A[0], A[2]))
else:
    #ide_ele = max(segfunc(A[-1], A[-2]), segfunc(A[-3], A[-4]))
    ide_ele = max(segfunc(A[0], A[1]), segfunc(A[2], A[3]))
    print(segfunc(A[0], A[1]), segfunc(A[2], A[3]))
'''
ide_ele = 0
#num:n以上の最小の2のべき乗
num =2**(n-1).bit_length()
seg=[ide_ele]*2*num

init(A)
ans = 0

#ans = max(query(1, n), ans)
#for i in range(1, n-1):
for i in range(n):
    #print(i, query(0, i), query(i+1, n))
    ans = max(segfunc(query(0, i), query(i+1, n)), ans)
#ans = max(query(0, n-1), ans)

print(ans)

Submission status: Runtime Error

Solution code:
import math

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

if N ==3:
    print(max(math.gcd(arr[0],arr[1]),math.gcd(arr[0],arr[2]),math.gcd(arr[1],arr[2])))
    exit()
ura_arr = arr[::-1]
left_gcd =[arr[0]]
right_gcd =[arr[-1]]

for i in range(1,N):
    left_gcd.append(math.gcd(left_gcd[-1],arr[i]))
    right_gcd.append(math.gcd(right_gcd[-1],arr[-1-i]))

ans = max(left_gcd[-2],right_gcd[-2])
for i in range(N-2):
    ans = max(ans,math.gcd(left_gcd[i],right_gcd[-1*(i+2)]))

print(ans)

Submission status: Runtime Error

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

for i in range(20):
    if i * a > t:
        ans = (a-1) * b
        break

print(ans)

Submission status: Runtime Error

Solution code:
a,b,t＝map(int,input().split())
print(t//a*b)

Submission status: Runtime Error

Solution code:
a,b,t＝map(int,input().split)
print(t//a*b)

Submission status: Runtime Error

Solution code:
"""
~~ Author : Bhaskar
~~ Dated : 07~06~2020
"""

import sys
from bisect import *
from math import floor,sqrt,ceil,factorial as F,gcd,pi,log
from itertools import chain,combinations,permutations,accumulate
from collections import Counter,defaultdict,OrderedDict,deque
from array import array
INT_MAX = sys.maxsize
INT_MIN = -(sys.maxsize)-1
mod = 1000000007
ch = "abcdefghijklmnopqrstuvwxyz"
lcm = lambda a,b : (a*b)//gcd(a,b)
setbit = lambda x : bin(x)[2:].count("1")

def solve():
    a,b,k = map(int,sys.stdin.readline().split())
    print(b*(k//a))

if __name__ == "__main__":
    try:
        sys.stdin = open("input.txt","r")
    except :
        pass
    solve()

Submission status: Runtime Error

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

Submission status: Runtime Error

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

print(t//a*b

Submission status: Runtime Error

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

print((T//A)*B)

Submission status: Runtime Error

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

Submission status: Runtime Error

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

Submission status: Runtime Error

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

Submission status: Runtime Error

Solution code:
a, b, t = int(input())
count = 0
for i in range(t):
  if i % a == 0:
    count +=1
print(count * b)

Submission status: Runtime Error

Solution code:
import sys
sys.setrecursionlimit(10**6) #再帰関数の上限
import math
from copy import copy, deepcopy
from operator import itemgetter
from bisect import bisect_left, bisect, bisect_right#2分探索
#bisect_left(l,x), bisect(l,x)#aはソート済みである必要あり。aの中からx未満の要素数を返す。rightだと以下
from collections import deque 
#deque(l), pop(), append(x), popleft(), appendleft(x)
##listでqueの代用をするとO(N)の計算量がかかってしまうので注意
from collections import Counter#文字列を個数カウント辞書に、
#S=Counter(l),S.most_common(x),S.keys(),S.values(),S.items()
from itertools import accumulate#累積和
#list(accumulate(l))
from heapq import heapify,heappop,heappush
#heapify(q),heappush(q,a),heappop(q) #q=heapify(q)としないこと、返り値はNone
import fractions#GCDなどはここからimportする！

def input(): return sys.stdin.readline()[:-1]
def printl(li): print(*li, sep="\n")
def argsort(s, return_sorted=False): 
    inds=sorted(range(len(s)), key=lambda k: s[k])
    if return_sorted: return inds, [s[i] for i in inds]
    return inds

class segtree():#seg=segtree(A),単位元とsegfuncを指定すること
    def __init__(self,A,ide=0):#単位元とsegfuncを指定すること
        n=len(A)
        num=2**(n-1).bit_length()
        seg=[ide]*(2*num-1)
        segfunc=self.segfunc
        self.ide,self.n,self.num,self.seg = ide, n, num, seg
        for i in range(n): seg[i+num-1]=A[i]#setvalue
        for i in range(num-2,-1,-1):seg[i]=segfunc(seg[2*i+1],seg[2*i+2])#build
            
    def segfunc(self,x,y):return fractions.gcd(x,y) #seg木の基本関数
        
    def update(self,k,x):#Aのk番目の要素をxに置き換える,計算量log(N)
        k += self.num-1
        seg,segfunc=self.seg,self.segfunc
        seg[k] = x
        while k:
            k = (k-1)//2
            seg[k] = segfunc(seg[k*2+1],seg[k*2+2])
    
    def query(self,p,q):#区間[p,q)の累積segfuncを求める,計算量log(N)
        if q<=p: return self.ide
        num,segfunc,seg=self.num,self.segfunc,self.seg
        p += num-1; q += num-2
        res=self.ide
        while q-p>1:
            if p&1 == 0: res = segfunc(res,seg[p])
            if q&1 == 1:
                res = segfunc(res,seg[q])
                q -= 1
            p,q = p//2, (q-1)//2
        if p == q: res = segfunc(res,seg[p])
        else: res = segfunc(segfunc(res,seg[p]),seg[q])
        return res

def main():
    mod = 10**9+7
    #w.sort(key=itemgetter(1),reversed=True)  #二個目の要素で降順並び替え

    N = int(input())
    #N, K = map(int, input().split())
    A = tuple(map(int, input().split())) #1行ベクトル
    #L = tuple(int(input()) for i in range(N)) #改行ベクトル
    #S = tuple(tuple(map(int, input().split())) for i in range(N)) #改行行列

    seg=segtree(A)
    ans=1
    for i in range(N):
        seg.update(i,0)
        ans=max(ans,seg.query(0,N))
        seg.update(i,A[i])
    print(ans)

if __name__ == "__main__":
    main()

Submission status: Runtime Error

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

Submission status: Runtime Error

Solution code:
a,b,c=map(int,input().split())
print(b*(t//a))

Submission status: Runtime Error

Solution code:
from fractions import gcd
N=int(input())
A=list(map(int,input().split()))
Asorted = sorted(A)


L=[0]*N
R=[0]*N
L[0]=A[0]
R[0]=A[N-1]

for n in range(1,N):
  L[n]=gcd(A[n],L[n-1])
  R[n]=gcd(A[N-n-1],R[n-1])
  
  ans=max(L[N-2],R[N-2])

for i in range(1,N-1):
  ans=max(ans,gcd(L[i-1],R[N-i-2]))

print(ans)

Submission status: Runtime Error

Solution code:
from fractions import gcd
N=int(input())
A=list(map(int,input().split()))
A = sorted(A)[:: -1]


L=[0]*N
R=[0]*N
L[0]=A[0]
R[0]=A[N-1]

for n in range(1,N):
  L[n]=gcd(A[n],L[n-1])
  R[n]=gcd(A[N-n-1],R[n-1])
  
  ans=max(L[N-2],R[N-2])

for i in range(1,N-1):
  ans=max(ans,gcd(L[i-1],R[N-i-2]))

print(ans)

Submission status: Runtime Error

Solution code:
from fractions import gcd
N=int(input())
A=list(map(int,input().split()))
print(A)

L=[0]*N
R=[0]*N
L[0]=A[0]
R[0]=A[N-1]

for n in range(1,N):
  L[n]=gcd(A[n],L[n-1])
  R[n]=gcd(A[N-n-1],R[n-1])
  
  ans=max(L[N-2],R[N-2])

for i in range(1,N-1):
  ans=max(ans,gcd(L[i-1],R[N-i-2]))

print(ans)

Submission status: Runtime Error

Solution code:
from fractions import gcd
N=int(input())
A=list(map(int,input().split()))
L=[0]*N
R=[0]*N
L[0]=A[0]
R[0]=A[N-1]
ans=0

for n in range(1,N):
  L[n]=gcd(A[n],L[n-1])
  R[n]=gcd(A[N-n-1],R[n-1])
  
  ans=max(L[N-2],R[N-2])

for i in range(1,N-1):
  ans=max(ans,gcd(L[i-1],R[N-i-2]))

print(ans)

Submission status: Runtime Error

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

Submission status: Runtime Error

Solution code:
a,b,c= map(int,input().split())
pritn((c//a)*b)

Submission status: Runtime Error

Solution code:
A, B, T = map(int, input().split())
cnt = 0

for i in range(0, T+0.5, A):
  cnt += B
print(cnt)

Submission status: Runtime Error

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

Submission status: Runtime Error

Solution code:
mod = 10 ** 9 + 7
mod2 = 2**61+1
from collections import deque
import heapq
from bisect import bisect_left, insort_left, bisect_right

def iip(listed=True):
    ret = [int(i) for i in input().split()]
    if len(ret) == 1 and not listed:
        return ret[0]
    return ret

def iip_ord():
    return [ord(i) - ord("a") for i in input()]


def main():
    ans = solve()
    if ans is not None:
        print(ans)

def solve():
    N = iip(False)
    A = iip()

    A.sort()
    A1 = [i for i in A]
    A2 = [i for i in A]

    ss1 = soinsuu_bunkai(A[0])
    ss2 = soinsuu_bunkai(A[1])
    ah1 = [1 for _ in A]
    ah2 = [1 for _ in A]


    #print(A)
    ak1 = 1
    for i in ss1:
        out = 0
        ahk = None
        for j, a in enumerate(A1):
            if a % i != 0:
                out += 1
                if out == 2: #2回アウトなら終了。
                    break
                else:
                    ahk = j
            else:
                A1[j] //= i
        if out == 2:
            continue
        elif out == 1:
            ah1[ahk] *= i
        else:
            ak1 *= i

    ak2 = 1
    for i in ss2:
        out = 0
        ahk = None
        for j, a in enumerate(A2):
            if a % i != 0:
                out += 1
                if out == 2: #2回アウトなら終了。
                    break
                else:
                    A2[j] //= i
                    ahk = j
            else:
                A1[j] //= i
        if out == 2:
            continue
        elif out == 1:
            ah2[ahk] *= i
        else:
            ak2 *= i

    #print(ak1)
    #print(ah1)
    #print(ak2)
    #print(ah2)
    print(max(ak1*max(ah1), ak2*max(ah2)))



#####################################################ライブラリ集ここから

def fprint(s):
    for i in s:
        print(i)

def split_print_space(s):
    print(" ".join([str(i) for i in s]))


def split_print_enter(s):
    print("\n".join([str(i) for i in s]))


def koenai_saidai_x_index(sorted_list, n):
    l = 0
    r = len(sorted_list)
    if len(sorted_list) == 0:
        return False
    if sorted_list[0] > n:
        return False

    while r - l > 1:
        x = (l + r) // 2
        if sorted_list[x] == n:
            return x
        elif sorted_list[x] > n:
            r = x
        else:
            l = x
    return l


def searchsorted(sorted_list, n, side):
    if side not in ["right", "left"]:
        raise Exception("sideはrightかleftで指定してください")

    l = 0
    r = len(sorted_list)

    if n > sorted_list[-1]:
        # print(sorted_list)
        return len(sorted_list)
    if n < sorted_list[0]:
        return 0

    while r - l > 1:
        x = (l + r) // 2
        if sorted_list[x] > n:
            r = x
        elif sorted_list[x] < n:
            l = x
        else:
            if side == "left":
                r = x
            elif side == "right":
                l = x

    if side == "left":
        if sorted_list[l] == n:
            return r - 1
        else:
            return r

    if side == "right":
        if sorted_list[l] == n:
            return l + 1
        else:
            return l


def soinsuu_bunkai(n):
    ret = []
    for i in range(2, int(n ** 0.5) + 1):
        while n % i == 0:
            n //= i
            ret.append(i)
        if i > n:
            break
    if n != 1:
        ret.append(n)
    return ret


def conbination(n, r, mod, test=False):
    if n <= 0:
        return 0
    if r == 0:
        return 1
    if r < 0:
        return 0
    if r == 1:
        return n
    ret = 1
    for i in range(n - r + 1, n + 1):
        ret *= i
        ret = ret % mod

    bunbo = 1
    for i in range(1, r + 1):
        bunbo *= i
        bunbo = bunbo % mod

    ret = (ret * inv(bunbo, mod)) % mod
    if test:
        # print(f"{n}C{r} = {ret}")
        pass
    return ret


def inv(n, mod):
    return power(n, mod - 2)


def power(n, p, mod_= mod):
    if p == 0:
        return 1
    if p % 2 == 0:
        return (power(n, p // 2, mod_) ** 2) % mod_
    if p % 2 == 1:
        return (n * power(n, p - 1, mod_)) % mod_


if __name__ == "__main__":
    main()

Submission status: Runtime Error

Solution code:
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

Submission status: Runtime Error

Solution code:
def main():
    from functools import reduce
    from math import gcd
    from collections import deque

    n, *a = map(int, open(0).read().split())
    p = deque(a)
    edge1 = reduce(gcd, a[1:])
    edge2 = reduce(gcd, a[:-1])
    full = reduce(gcd, a)
    ans = max([edge1, edge2, full])
    gl = p.pop()
    tmp = gl
    for i in range(n - 2):
        tmp2 = p.pop()
        gr = reduce(gcd, p)
        gl = gcd(gl, tmp)
        tmp = tmp2
        g = gcd(gl, gr)
        ans = max(ans, g)

    print(ans)


if __name__ == '__main__':
    main()

Submission status: Runtime Error

Solution code:
def main():
    from functools import reduce
    from fractions import gcd
    from collections import deque

    n, *a = map(int, open(0).read().split())
    p = deque(a)
    edge1 = reduce(gcd, a[1:])
    edge2 = reduce(gcd, a[:-1])
    full = reduce(gcd, a)
    ans = max([edge1, edge2, full])
    gl = p.pop()
    tmp = gl
    for i in range(n - 2):
        tmp2 = p.pop()
        gr = reduce(gcd, p)
        gl = gcd(gl, tmp)
        tmp = tmp2
        g = gcd(gl, gr)
        ans = max(ans, g)

    print(ans)


if __name__ == '__main__':
    main()

Submission status: Runtime Error

Solution code:
mport math 

a,b,c= input().split()
x,y,z=(int(a),int(b),int(c))
p = math.floor(z / x)
print(int(p * y))

Submission status: Runtime Error

Solution code:
N = int(input())
V = list(map(int,input().split()))
C = list(map(int,input().split()))
sa = 0

for i in range(N):
    if v[i] - c[i]>0:
        sa += v[i]-c[i]

print(sa)

Submission status: Runtime Error

Solution code:
N = int(input())

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

INF = 10**6

ind = INF
for i in range(len(A)):
    if A[i]>=0:
        ind = i
        break
    else:
        A[i] *= -1

if ind == INF:
    ind = N

if ind %2 == 0:
    print(sum(A))
elif ind==N:
    print(sum(A)-2*A[ind-1])
else:
    print(sum(A)-2*min(A[ind], A[ind-1]))

Submission status: Runtime Error

Solution code:
A,B,T = map(int,input().split)
count = int((T+0.5)/A)
ans = B*count
print(ans)