Problem:


Score : 100 points

Problem Statement

N of us are going on a trip, by train or taxi.

The train will cost each of us A yen (the currency of Japan).

The taxi will cost us a total of B yen.

How much is our minimum total travel expense?

Constraints

All values in input are integers.

1 \leq N \leq 20

1 \leq A \leq 50

1 \leq B \leq 50

Input

Input is given from Standard Input in the following format:

N A B

Output

Print an integer representing the minimum total travel expense.

Sample Input 1

4 2 9

Sample Output 1

8

The train will cost us 4 \times 2 = 8 yen, and the taxi will cost us 9 yen, so the minimum total travel expense is 8 yen.

Sample Input 2

4 2 7

Sample Output 2

7

Sample Input 3

4 2 8

Sample Output 3

8



Sample input:
4 2 9


Sample output:
8

Submission status: Runtime Error

Solution code:
L, R = map(int, input().split())
mod = 2019
ans = mod + 100

if R - L >= 3000:
    print(0)
else:
    L %= mod
    R %= mod
    for i in range(L, R):
        for j in range(i + 1, R + 1):
            m = (i * j) % mod
            if m < ans:
                ans = m
print(ans)

Submission status: Runtime Error

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

Submission status: Runtime Error

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

Submission status: Runtime Error

Solution code:
l,r=map(int,input().split())
l0=l%2019
r0=r%2019
if r-l>=2019 or l0==0 or r0==0:
    print(0)
elif l-l%2019+2019<=r:
    print(0)
else:
    ans=2019
    for i in range(l0,r0):
        for j in range(i+1,r0+1):
            if (i*j)%2019<ans:
                ans=(i*j)%2019
            if ans==1:
                break
        if ans==1:
            break
    print(ans)

Submission status: Runtime Error

Solution code:
#include <iostream>
#include <vector>
#define rep(i, n) for (int i = 0; i < n; i++)
using namespace std;
using ll = long long;
using P = pair<int, int>;

int main()
{
    int n, a, b;
    cin >> n >> a >> b;
    cout << min(n * a, b) << endl;
    return 0;
}

Submission status: Runtime Error

Solution code:
n,a,b=map(int(input().split()));print(min([n*a,b]))

Submission status: Runtime Error

Solution code:
n,a,b=map(int(input()));print(min([n*a,b]))

Submission status: Runtime Error

Solution code:
n,a,b = map(input().split())
print(n*a if n*a<b else b)

Submission status: Runtime Error

Solution code:
n,d = map(int,input().split())
x = [list(map(int,input().split())) for _ in range(n)]
ans = 0
for i in range(n):
	for j in range(i):
		ans += (sum((a-b)**2 for a,b in zip(x[i],x[j]))**0.5).is_integer()
print(ans)

Submission status: Runtime Error

Solution code:
L, R = map(int, input().split())
ans = 2019
for i in range(L, R):
    for j in range(i + 1, R + 1):
        if i * j % 2019 < ans:
            ans = i * j % 2019
        if ans == 0:
            exit()
print(ans)

Submission status: Runtime Error

Solution code:
l = input().split()
N, A, B = [int(num) for i in l]
NA = N * A
print(min(NA,B))

Submission status: Runtime Error

Solution code:
N = input()
A = input()
B = input()

N = int(N)
A = int(A)
B = int(B)

if N * A > B:
  print(N*A)
else:
  print(B)

Submission status: Runtime Error

Solution code:
L,R = map(int, input().split())

l = L % 2019
r = R % 2019

m = 10*9

for i in range(l, r+1):
  for n in range(i+1, r+1):
    k = i * n % 2019

    if m > k:
      m = k

print(m)

Submission status: Runtime Error

Solution code:
def main():
    n = map(int, input().split())

    train = n * a
    taxi = b

    print(min(train,taxi))

if __name__ == '__main__':
    main()

Submission status: Runtime Error

Solution code:
N,D = [int(i) for i in input().split()]
lagd = []
for i in range(N):
    lagd.append([int(i) for i in input().split()])
lngs = D - 1
def kyoricac(daone,datwo,d):
    keka = []
    n = 0
    wa = 0
    while n <= d:
        wa = (daone[n] - datwo[n])**2
        keka += [wa]
        n += 1
    wa = sum(keka)
    kaesi = float(wa ** (1/2))
    return kaesi
ans = 0
fst = 1
for i in range(N):
    for n in range(fst,N):
        flag = float(kyoricac(lagd[i],lagd[n],lngs))
        if flag.is_integer() == True:
            ans += 1
    fst += 1
print(ans)

Submission status: Runtime Error

Solution code:
N,D = [int(i) for i in input().split()]
for i in range(N):
    lagd.append([int(i) for i in input().split()])
lngs = D - 1
def kyoricac(daone,datwo,d):
    keka = []
    n = 0
    wa = 0
    while n <= d:
        wa = (daone[n] - datwo[n])**2
        keka += [wa]
        n += 1
    wa = sum(keka)
    kaesi = float(wa ** (1/2))
    return kaesi
ans = 0
fst = 1
for i in range(N):
    for n in range(fst,N):
        flag = float(kyoricac(lagd[i],lagd[n],lngs))
        if flag.is_integer() == True:
            ans += 1
    fst += 1
print(ans)

Submission status: Runtime Error

Solution code:
L,R = map(int,input().split())

ans = 2019 ** 2

if R - L >= 2018:
  ans = 0
  print(ans)
else: 
  for i in range(L,R):
    for j in range(L + 1,R + 1):
      mod = (i * j) % 2019 
      if mod < ans:
        ans = mod
      elif mod == 0:
        ans = 0
        break
  print(ans)

Submission status: Runtime Error

Solution code:
L,R = map(int,input().split())

#区間の両端を除いた数=2017より長ければ2019の倍数が含まれているので0が解

ans = 2019 ** 2

for i in range(L,R):
  for j in range(L + 1,R):
    mod = (i * j) % 2019 
    if mod < ans:
      ans = mod
    elif mod == 0:
      ans = 0
      break
print(ans)

Submission status: Runtime Error

Solution code:
l, r = map(int, input().split())
mod = []
for i in range(l, min(r+1,l+2019)):
    mod.append(i % 2019)
mod = sorted(list(mod))
print(mod[0] * mod[1])

Submission status: Runtime Error

Solution code:
n,a,b = map(int, input().split())
ans=b
tr = n*a
if tr < b
	ans=tr
print(ans)

Submission status: Runtime Error

Solution code:
import java.util.*;
public class Main{
  public static void main(String args[]){
    Scanner sc = new Scanner(System.in);
    int n = sc.nextInt();
    int a = sc.nextInt();
    int b = asc.nextInt();
    if(n*a>=b){
      System.out.println(b);
    }else{
      System.out.println(n*a);
    }
  }
}

Submission status: Runtime Error

Solution code:

N, A, B  = input()

train = N * A

if(train < B) :
  print(train)
else:
  print(B)

Submission status: Runtime Error

Solution code:
chimpo = N
manko = A
B
AC

Submission status: Runtime Error

Solution code:
N,A,B = map(int,input().split)
a = N*A
print(min(a,B))

Submission status: Runtime Error

Solution code:
i,j=map(int,input().split())

i%=2019;j%=2019

j+=2019
  
ans=2019

for x in range (i,j+1):
  for y in range (x+1,j+1):
    ans=min(ans,x*y%2019)
  
print(int(ans))

Submission status: Runtime Error

Solution code:
N,A,B = map(int,input().slit())
if N*A<B:
  print(N*A)
elif N*A>B:
  print(B)
else:
  print()

Submission status: Runtime Error

Solution code:
N,A,B = map(int,input().slit())
if N*A<=B:
  print(N*A)
else N*A>=B:
  print(B)

Submission status: Runtime Error

Solution code:
n, a, b = map(int, raw_input().spit())
if b > a * a:
    print n * a
else:
    print b

Submission status: Runtime Error

Solution code:
n, a, b = map(int,. raw_input().spit())
if b > a * a:
    print n * a
else:
    print b

Submission status: Runtime Error

Solution code:
N, A, B = map(int, input().split())
ans = []
for i in range(1, N):
    ans.append(A * i + B / N * (N - i))
print(min(ans))

Submission status: Runtime Error

Solution code:
N, A, B = map(int, input().split())
ans = []
for i in range(1, N):
    ans.append(A * i + B * (N - i))
print(min(ans))

Submission status: Runtime Error

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

# 解法メモ
# ひとつでも山の雨の量がわかれば全て求まる
# 3つの山があり、1つめの山の値をxとしたとき
# 1つめ: x
# 2つめ：A1 - x
# 3つめ：A2 - (A1 - x)
# 1つめ：A3 - (A2 - (A1 - x))
# 1つめ２つを式にする
# x = A3 - (A2 - (A1 - x))
# x = A3 - A2 + A1 - x
# 2x = A3 - A2 + A1
summary = 0

for i in range(N):
    if i % 2 == 0:
        summary += A[i]
    else:
        summary -= A[i]

for i in range(N):
    print(summary)
    summary = (A[i] - (summary//2)) * 2

Submission status: Runtime Error

Solution code:
import sys
sys.setrecursionlimit(10**7)
N, K = map(int, input().split())

e = [[] for i in range(N)]
for i in range(N - 1):
    a, b = map(int, input().split())
    a -= 1
    b -= 1
    e[a].append(b)
    e[b].append(a)

col = [-1 for i in range(N)]
col[0] = 0
MOD = 10 ** 9 + 7


def dfs(i, ans, depth):
    if depth == 1:
        num = K - 1
    else:
        num = K - 2
    for v in e[i]:
        if col[v] == -1:
            col[v] = 0
            ans = (ans * num) % MOD
            num -= 1
            ans = dfs(v, ans, depth+1)

    return ans


print(dfs(0, K, 1))

Submission status: Runtime Error

Solution code:
#%%
import sys
def input():
    return sys.stdin.readline().rstrip()

def main():
    L, R = map(int, input().split())

    R_r = R%2019
    if (R - L) >= R_r :
        print(0)
    else:
        L_r = L%2019
        ans = (L_r*(L_r+1))%2019
        for l in range(L_r, R_r):
            for r in range(l+1, R_r+1):
                ans = min(ans, (l*r)%2019)
        print(ans)

# %%
if __name__ == '__main__':
    main()

# %%
# from atcoder_test import doTest
# doTest("abc133","c",main)

Submission status: Runtime Error

Solution code:
#%%
import sys
def input():
    return sys.stdin.readline().rstrip()

def main():
    L, R = map(int, input().split())

    R_r = R%2019
    if (R - L) > R_r :
        print(0)
    else:
        L_r = L%2019
        ans = L_r*(L_r+1)%2019
        for l in range(L_r, R_r):
            for r in range(l+1, R_r+1):
                ans = min(ans, l*r%2019)
        print(ans)

# %%
if __name__ == '__main__':
    main()

# %%
# from atcoder_test import doTest
# doTest("abc133","c",main)

Submission status: Runtime Error

Solution code:
L, R = map(int, input().split())
li = []
for i in range(L, R+1):
  li.append(i%2019)
#print(li)
a = min(li)
li.remove(min(li))
b = min(li)
li.remove(min(li))
print(a*b)

Submission status: Runtime Error

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

Submission status: Runtime Error

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

Submission status: Runtime Error

Solution code:
import math
N, D = map(int, input().split())
t = []
for i in range(N):
    t.append(list(map(int, input().split())))
count = 0
sum = 0
for i in range(0, N-1):
    for j in range(i + 1, N):
      for d in range(D):
        sum += pow(t[i][d] - t[j][d], 2)
        sqrt = math.sqrt(sum)
      if sqrt == int(sqrt):
        count += 1
      sum = 0
      sqrt = 0
print(count)

Submission status: Runtime Error

Solution code:
from math import sqrt
n,d=map(int, input().split())
x=[list(map(int, input().split())) for i in range(n)]

ans=0
tmp = 0

for i in range(n):
  for j in range(i+1, n):
    xi,xj = x[i],x[j]
    for k in range(d):
      tmp += (xi[k]-xj[k]) ** 2
      
    if sqrt(tmp)%1==0:
      ans += 1

print(ans)

Submission status: Runtime Error

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

Submission status: Runtime Error

Solution code:
N,A,B = map(int,input().split)
kake = N*A

print(min(kake,B))

Submission status: Runtime Error

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

Submission status: Runtime Error

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

print(min(N*A,B)

Submission status: Runtime Error

Solution code:
a,b,c = int(input())
print(min(a*b,c))

Submission status: Runtime Error

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

Submission status: Runtime Error

Solution code:
import numpy as np

N, D = map(int, input().split())

X = []
X = np.vstack([input().split() for i in range(N)])

count = 0

for i in range(N - 1):
  for j in range(N - (i + 1)):
    r = 0
    for k in range(D):
      r += (int(X[i, k]) - int(X[i + (j + 1), k])) ** 2
  
    if np.sqrt(r).is_integer():
      count += 1
    
print(count)

Submission status: Runtime Error

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

if a*n>=b:
  print(a*n)
else:
  prinb(b)

Submission status: Runtime Error

Solution code:
A =int(input("電車代一人分"))
N=int(input("人数"))
B =int(input("タクシー代"))

if A * N > B:
     print(B)
elif B > A * N:
     print(A * N)

Submission status: Runtime Error

Solution code:
A = input(("電車代一人分"))
N= input(("人数"))
B = input(("タクシー代"))
int(input())
if A * N > B:
     print(B)
elif B > A * N:
     print(A * N)

Submission status: Runtime Error

Solution code:
N,D=map(int,input().split())
c=0
X=[[0]*D]*N
for l in range(N):
    X[l]=list(map(int,input().split()))
for i in range(N-1):
    l=0
    for j in range(i+1,N):
        for k in range(D):
            l+=(X[i][k]-X[j][k])**2
        if pow(l,0.5).is_integer() == True:
            c+=1
print(c)

Submission status: Runtime Error

Solution code:
print(min(int(input())*int(input()),int(input())))

Submission status: Runtime Error

Solution code:
N = int(input())
A = int(input())
B = int(input())

n = N * A
p = B

if n < p :
    print(n)
else :
    print(p)

Submission status: Runtime Error

Solution code:
N = int(input())
A = int(input())
B = int(input())

n = N * A
p = B

if n < p :
    print(p)
else :
    print(n)

Submission status: Runtime Error

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

Submission status: Runtime Error

Solution code:
import math

n,D = map(int,input().split())

point = []
for _ in range(n):
  x = list(map(int, input().split()))
  point.append(x)

cnt = 0
for i in range(n-1):
  for j in range(i+1, n):
    dist = 0
    for d in range(D):
      dist += (point[i][d] - point[j][d])**2
    dist = math.sqrt(dist)
    if int(dist) == dist:
      cnt += 1
print(cnt)

Submission status: Runtime Error

Solution code:
inpot = input()
j = inpot.split()
n = j[0]
a = j[1]
b = j[2]

if (n*a) > b:
  print(b)
else:
  print(n*a)

Submission status: Runtime Error

Solution code:
inpot = input()
n = int(inpot[0])
a = int(inpot[2])
b = int(inpot[4])

if (n*a) > b:
  print(b)
else:
  print(n*a)

Submission status: Runtime Error

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

Submission status: Runtime Error

Solution code:
N,A,B = map(int,input().split)
if N*A>=B:
    print(N*A)
else:
    print(B)

Submission status: Runtime Error

Solution code:
from sys import stdin
li = list(map(int,stdin.readline().rstrip.split()))
if li[1] > li[2]:
    print(li[0]*li[1])
else:
    print(li[0]*li[2])

Submission status: Runtime Error

Solution code:
from sys import stdin

li = list(map(int,stdin.readline().rstrip.split()))

if li[1] > li[2]:
    print(li[0]*li[1])
else:
    print(li[0]*li[2])

Submission status: Runtime Error

Solution code:
N,A,B=map(int,input().split())
train=N*A
taxi=B
if train<=taxi:
    print(train)
else print(taxi)

Submission status: Runtime Error

Solution code:
n,a,b-map(int,input().split())
print(min(a*n,b))

Submission status: Runtime Error

Solution code:
#include <iostream>
#include <algorithm>
using namespace std;

int main(void)
{
    cin.tie(0);
    ios::sync_with_stdio(0);
    int n,a,b;
    cin >> n >> a >> b;
    cout << min(a*n,b) << "\n";
    return 0;
}

Submission status: Runtime Error

Solution code:
N = int(input())
A = int(input())
B = int(input())

N *= A

if (N) < B:
    print(N)
else:
    print(B)

Submission status: Runtime Error

Solution code:
N = int(input())
A = int(input())
B = int(input())

if (N*A) < B:
    print(N*A)
else:
    print(B)

Submission status: Runtime Error

Solution code:
N = int(input())
A = int(input())
B = int(input())

if N*A < B:
    print(N*A)
else:
    print(B)

Submission status: Runtime Error

Solution code:
n, a, b= map(int, input().split())
if b < na:
  print(b)
else:
  print(na)

Submission status: Runtime Error

Solution code:
ns = input().split(" ")
if int(ns[0])*int(ns[1]) <= int(ns[2]):
  print(int(ns[0])*int(ns[1]))
else:
  print(int(ns[2])

Submission status: Runtime Error

Solution code:
n,a,b = map(input().split())
ans = 0
if n * a > b:
  ans += b
else:
  ans += n * a
print(ans)

Submission status: Runtime Error

Solution code:
# C - Remainder Minimization 2019(ABC133)
L,R=map(int, input().split())
A=L%2019
B=R%2019
m=A*(A+1)%2019
if L//2019==R//2019 and A!=0 and B!=0:
    for i in range(A,B+1):
        if int(2019/i)<B+1 and i<B:
            if i%3==0:
                print(0)
                break
            else:
                M=(int(2019/i)+1)*i
                m=min(m,M)
        elif i==B:
            print(m)
else:
    print(0)

Submission status: Runtime Error

Solution code:
l, r = [int(x) for x in input().split(' ')]

if (r-l) > 2019:
  print(0)
else:
  a = [x for x in range(l, r+1)]
  res = [i*j%2019 for i in a for j in a if i!=j]
  print(min(res))

Submission status: Runtime Error

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

Submission status: Runtime Error

Solution code:
# C - Remainder Minimization 2019(ABC133)
L,R=map(int, input().split())
A=L%2019
B=R%2019
if L//2019==R//2019 and A!=0:
    for i in range(A,B+1):
        if int(2019/i)<B+1:
            if 2019/i==int(2019/i):
                print(0)
                break
            else:
                if A*(A+1)>(int(2019/4)+1)*i-2019:
                    print((int(2019/4)+1)*i-2019)
                    break
                else:
                    print(A*(A+1))
                    break
        elif i==B:
            print(A*(A+1))
else:
    print(0)

Submission status: Runtime Error

Solution code:
function main(input){
  const   args = input.split(" ");
  const N = args[0];
  const   A = args[1];
  const   B = args[2];
  if(N*A>B){
console.log(B);
  }else{
console.log(N*A);}
}
main(require('fs').readFileSync('/dev/stdin', 'utf8'));

Submission status: Runtime Error

Solution code:
n =  int(input())
a = int(input())
b = int(input())

if n * a < b:
  print(n * a)
else:
  print(b)

Submission status: Runtime Error

Solution code:
N, A, B = int(input().split())
print(min(N*A,B))

Submission status: Runtime Error

Solution code:
L,R=map(int,input().split())
a=[]
if R-L>=2019:
	print(0)
else:
	for i in range(L,R+1):
		for j in range(i+1,R+1):
			a.append(((i%2019)*(j%2019))%2019)
 
	print(min(a))

Submission status: Runtime Error

Solution code:
A,P = map(int,input().split())
print((A*3+P)//2)

Submission status: Runtime Error

Solution code:
N = int(input())
A = int(input())
B = int(input())

print(min(N*A,B))

Submission status: Runtime Error

Solution code:
N = int(input())
A = int(input())
B = int(input())

print(max(N*A,B))

Submission status: Runtime Error

Solution code:
n, a, b = (int(x) for x in input().splint())
sum = n * a
if sum <= b :
  print(sum)
else :
  print(b)

Submission status: Runtime Error

Solution code:
L, R = map(int, input().split())
small1 = L % 2019
small2 = R % 2019
for i in range(L, R+1):
    ans = i % 2019
    if  ans < small1:
        small2 = small1
        small1 = ans
    elif ans < small2:
        small2 = ans
    if small1 == 0:
        break
print(small1 * small2)

Submission status: Runtime Error

Solution code:
n,a,b=amap(int,input().split())
print(min(b,a*n))

Submission status: Runtime Error

Solution code:
l,r = map(int,input().split())
if( r-l > 2019 ):
    print (0)
else :
    x = 2020
    for i in range(l,r):
        if x == 0 :
            break
        for j in range(i+1,r):
            x = min((i*j)%2019, x)
    print(x)

Submission status: Runtime Error

Solution code:
n,d = map(int,input().split())
w = [list(map(int,input().split())) for a in range(n)]
c = 0
 
for i in range(n-1):
  for j in range(i+1,n+1):
    b = 0
    for m in range(d):
      b += (w[i][m]-w[j][m])**2
    if (b**0.5)　== float(int(b**0.5)):
      c += 1
      
print(c)

Submission status: Runtime Error

Solution code:
n,d = map(int,input().split())
x = [list(map(int,input().split())) for a in range(n)]
c = 0
 
for i in range(n-1):
  for j in range(i+1,n):
    b = 0
    for m in range(d):
      b += (x[i][m])-x[j][m])**2
    if (b**0.5)　== float(int(b**0.5)):
      c += 1
      
print(c)

Submission status: Runtime Error

Solution code:
n,d = map(int,input().split())
x = [list(map(int,input().split())) for a in range(n)]
c = 0
 
for i in range(n-1):
  for j in range(i+1,n+1):
    b = 0
    for m in range(d):
      b += (int(x[i][m])-int(x[j][m]))**2
    if (b**0.5)　== float(int(b**0.5)):
      c += 1
      
print(c)

Submission status: Runtime Error

Solution code:
n, a, b = map(int, input().split)
m = n*b
if m < a :
    print(m)
else:
    print(a)

Submission status: Runtime Error

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

if n * a < b:
	print(n*a)
else:
	print(b)

Submission status: Runtime Error

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

Submission status: Runtime Error

Solution code:


n, a, b = map(int, input().input())

print(min(b,a*n))

Submission status: Runtime Error

Solution code:
l,r = map(int,input().split())
b = sorted([i%2019 for i in range(l,min(r+1,l+2019))])
print(b[0]*b[1])

Submission status: Runtime Error

Solution code:
tmp=input().split()
n=int(tmp[0])
d=int(tmp[1])
xn = [0]*n
num = 0

for i in range(n):
  xn[i] = input().split()
    
for i in range(n):
  for j in range(i+1, n):
    dist = 0
    for k in range(d):
      dist = dist + pow(int(xn[i][k])-int(xn[j][k]), 2)
#    print("test",dist)
#    print(int(pow(int(pow(dist,0.5)), 2)))
    if dist == int(pow(int(pow(dist,0.5)), 2)):
      num += 1
print(num)

Submission status: Runtime Error

Solution code:
def resolve():
    l, r = map(int, input().split())
    result = 2018
    for i in range(l, r):
        for j in range(i+1, r+1):
            result = min(result, (i * j) % 2019)
            if result == 0:
                print(0)
                return
    print(result)
    
resolve()

Submission status: Runtime Error

Solution code:
n, a, b = map( int, input() )
print( min( n*a, b ) )

Submission status: Runtime Error

Solution code:
List = list(map(int,input().split()))
L = List[0]
R = List[1]
count_dict = {}
count_list = []
if R - L >= 2019:
    print(0)
else:
    for i in range(L,R+1):
        for j in range(i,R+1):
            count_dict[i,j]  = (i * j) % 2019

    for i in count_dict.values():
        count_list.append(i)

    sort_list = sorted(count_list)
    print(sort_list[0])

Submission status: Runtime Error

Solution code:
n = int(input())
a = int(input())
b = int(input())

if a*n > b:
	print(b)
else:
	print(a*n)

Submission status: Runtime Error

Solution code:
def main():
    l, r = list(map(int, input().split(" ")))
 
    m = 3000
    for i in range(l, r):
        for j in range(i+1, r+1):
            r = (i*j) % 2019
            if r == 0:
                print(0)
                return
            if m > r:
              m = r
    print(m)

main()

Submission status: Runtime Error

Solution code:
def main():
    l, r = list(map(int, input().split(" ")))
 
    m = 3000
    for i in range(l, r):
        for j in range(i+1, r+1):
            r = (i*j) % 2019
            if r == 0:
                print(0)
                return
            if m > r:
                m = r
    print(m)
     
      
main()

Submission status: Runtime Error

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

print(min(n*a,b))

Submission status: Runtime Error

Solution code:
n = input('整数を入力してください：')

while n.isdigit() == False or int(n) < 1 or int(n) > 20:
    print('Error')
    n = input('整数を入力してください：')
else:
    n = int(n)
n = int(n)


a = input('整数を入力してください：')

while a.isdigit() == False or int(a) < 1 or int(a) > 50:
    print('Error')
    a = input('整数を入力してください：')
else:
    a = int(a)
a = int(a)

b = input('整数を入力してください：')

while b.isdigit() == False or int(b) < 1 or int(b) > 50:
    print('Error')
    b = input('整数を入力してください：')
else:
    b = int(b)
b = int(b)

train = n * a
taxi = b

expense = [train,taxi]

print(min(expense))

Submission status: Runtime Error

Solution code:
l, r = map(int, input().split())
 
i_rest = l % 2019
for i in range(l, r):
  i_rest_next = i % 2019
  if i_rest_next <= i_rest:
    i_rest = i_rest_next
    count_i = i
min_i = i_rest

i_rest = (count_i+1) % 2019
for i in range(count_i+1, r+1):
  i_rest_next = i % 2019
  if i_rest_next <= i_rest:
    i_rest = i_rest_next
min_j = i_rest
 
print(min_i * min_j)

Submission status: Runtime Error

Solution code:
l, r = map(int, input().split())

i_rest = l % 2019
count_i
for i in range(l, r):
  i_rest_next = i % 2019
  if i_rest_next < i_rest:
    i_rest = i_rest_next
    count_i = i
    
min_i = i_rest

i_rest = (count_i+1) % 2019
for i in range(count_i+1, r+1):
  i_rest_next = i % 2019
  if i_rest_next < i_rest:
    i_rest = i_rest_next

min_j = i_rest

print(min_i * min_j % 2019)

Submission status: Runtime Error

Solution code:
l, r = map(int, input().split())
mod1 = []
mod2 = []
for i in range(l,r+1):
  mod1.append(i%2019)

for i in range(len(mod1)-1):
  for j in range(i+1,len(mod1)):
    mod2.append((mod1[i]*mod1[j])%2019)
print(min(mod2))

Submission status: Runtime Error

Solution code:
N,A,B=map(int,input())
print(min(A*N,B))

Submission status: Runtime Error

Solution code:
import math
n,d = list(map(int, input().split()))
x = [list(map(int, input().split())) for N in range(n)]
 
cnt = 0
 
for i in range(n):
  for j in range(i+1,n):
    kaijou = 0
    for k in d:
      kaijou = kaijou + abs(x[j][k]-x[i][k])**2
    if math.sqrt(kaijou).is_integer():
      cnt += 1
      
print(cnt)

Submission status: Runtime Error

Solution code:
import sys
L, R = map(int,input().split())
a=[]

for i in range(L, R):
	for j in range(i+1,R+1):
		a.append((i*j)%2019)
		if 0 in a:
			print(0)
			sys.exit()
print(min(a))

Submission status: Runtime Error

Solution code:
import numpy as np

if __name__ == '__main__':
	N = int(input())
	dam = np.array(list(map(int, input().split())))

	index_ = np.array([1 if i % 2 == 0 else -1 for i in range(N)])
	ans = np.array([])
	for i in range(N):
		ans = np.append(ans, np.dot(dam, index_))
		index_ = np.roll(index_, 1)
	ans = [str(int(i)) for i in ans]

	print(' '.join(ans))

Submission status: Runtime Error

Solution code:
import numpy as np
 
N, D = list(map(int, input().split()))
full_list = []
for i in range(N):
  full_list.append(list(map(int, input().split())))
 
result = 0
 
for i in range(N):
  for j in range(N-i-1):
    length = 0
    for s in range(D):
      length += (full_list[i][s] - full_list[j][s]) ** 2
    result += 1 if np.sqrt(length).is_integer() else 0
 
print(result)

Submission status: Runtime Error

Solution code:
import numpy as np
 
N, D = list(map(int, input().split()))
full_list = []
for i in range(N):
  full_list.append(list(map(int, input().split())))
 
result = 0
 
for i in range(N):
  for j in range(N-i-1):
    length = 0
    for s in range(D):
      length += (full_list[i][s] - full_list[j][s]) ** 2
    result += 1 if np.sqrt(length).is_integer() == True else 0
 
print(result)

Submission status: Runtime Error

Solution code:
ソースコード 

Copy
Copy
import numpy as np
 
N, D = list(map(int, input().split()))
full_list = []
for i in range(N):
  full_list.append(list(map(int, input().split())))
 
result = 0
 
for i in range(N):
  for j in range(N-i-1):
    length = 0
    for s in range(D):
      length += (full_list[i][s] - full_list[j][s]) ** 2
    result += 1 if np.sqrt(length).is_integer() == True else 0
 
print(result)

Submission status: Runtime Error

Solution code:
#include <iostream>
using namespace std;
int main(){
  int n, a, b;
  cin >> n >> a >> b;
  cout << min(n*a, b) << endl;
}

Submission status: Runtime Error

Solution code:
N,A,B = map(int, input())

print(min(N*A, B))

Submission status: Runtime Error

Solution code:
N,A,B=map(input().split())
print(max(N*A,B))

Submission status: Runtime Error

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

Submission status: Runtime Error

Solution code:
# -*- coding: utf-8 -*-
import itertools
import math

N, D = map(int, input().split())

X = [[0 for x in range(D)] for y in range(N)]

for n in range(N):
    X[n] = list(map(int, input().split()))

ans = 0
for target in itertools.combinations(X, 2):
    res = sum([(y - z) ** 2 for y, z in zip(target[0], target[1])])
    res = math.sqrt(res)
    if res.is_integer():
        ans += 1

print(ans)

Submission status: Runtime Error

Solution code:
package main

import(
    "fmt"
    "math"
    )

func main(){
    var N,A,B float64
    fmt.Scan(&N,&A,&B)
    fmt.Println(math.Min(N*A,B))
}

Submission status: Runtime Error

Solution code:
N,A,B = map(int(),input().strip())

A = A * N

if (A < B):
	print(A)
else:
	print(B)

Submission status: Runtime Error

Solution code:
N,A,B = map(int().input().strip())

A = A * N

if (A < B):
	print(A)
else:
	print(B)

Submission status: Runtime Error

Solution code:
N,A,B = map(int(),input(),strip())

A = A * N

if (A < B):
	print(A)
else:
	print(B)

Submission status: Runtime Error

Solution code:
n=int(input())
a=int(input())
b=int(input())
if n*a>b :
  print(n*a)
else:
  print(b)

Submission status: Runtime Error

Solution code:
n=int(input())
a=int(input())
b=int(input())
if(n*a>b):
  print(n*a)
else:
  print(b)

Submission status: Runtime Error

Solution code:
n,a,b = int(input().split())
if(n*a>b):
  print(n*a)
else:
  print(b)

Submission status: Runtime Error

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

if NA > B:
    print(B)
elif NA < B:
    print(AN)
else:
    print(AN)

Submission status: Runtime Error

Solution code:
N = int(input())
A = int(input())
B = int(input())

if N*A > B:
    print(B)
elif N*A < B:
    print(A*N)
else:
    print(A*N)

Submission status: Runtime Error

Solution code:
s=list(input())

if int(s[0])* int(s[1]) > int(s[2]):
    print(s[2])
else:
    print(int(s[0])* int(s[1]))

Submission status: Runtime Error

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

print(max(A*N,B))

Submission status: Runtime Error

Solution code:
n,a,b = map(int, input().split())
if a * n < b:
  print(a * n)
else:
  printf(b)

Submission status: Runtime Error

Solution code:
N,A,B = [ int(i)for i in input().split()]
c = N*A
if c >= B:
    print(B)
elif c <= B:
    print(C)

Submission status: Runtime Error

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

if N * A >= B:
    print(B)
else:
    print(N * A)

Submission status: Runtime Error

Solution code:
import math
a = 0
b = 1
N, D = map(int, input().split())
ls = [list(map(int, input().split()))for i in range(N)]
for i in range(N):
    for j in range(i, N):
        for k in range(D):
            a += (ls[i][k] - ls[j][k]) ** 2
            if math.sqrt(a).is_integer() is True:
                b += 1

print(b)

Submission status: Runtime Error

Solution code:
import numpy as np
n,a,b=map(int, input().split())
print([n*a, n*b].min())

Submission status: Runtime Error

Solution code:
n,a,b = list(map(int, input().split()))
d = n*a
t = n*b
print(int(np.min([d, t])))

Submission status: Runtime Error

Solution code:
n,a,b = list(map(int, input().split()))
d = n*a
t = n*b
print(np.min([d, t]))

Submission status: Runtime Error

Solution code:
n,a,b = list(map(int, input().split()))
taxi = n*a
densya = n*b
print(np.min([taxi, densya]))

Submission status: Runtime Error

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

Submission status: Runtime Error

Solution code:
# -*- coding: utf-8 -*-
N = int(input())
A,B = map(int,input().split())
train = N*A
cab = B
result = train - cab

if result >= 0:
    print(cab)
else:
    print(train)

Submission status: Runtime Error

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

#output
if N*A > B:
  print(B)
elif:
  print(N*A)

Submission status: Runtime Error

Solution code:
a = input().split()

N = int(a[1])
A = int(a[2])
B = int(a[3])

if A * N  >= B * N:
  print B * N
else:
  print A * N

Submission status: Runtime Error

Solution code:
a,b,c = linst(map(int,input()))
if a*b < c:
  print(a*b)
else:
  print(c)

Submission status: Runtime Error

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