s_id
stringlengths
10
10
p_id
stringlengths
6
6
u_id
stringlengths
10
10
date
stringlengths
10
10
language
stringclasses
1 value
original_language
stringclasses
11 values
filename_ext
stringclasses
1 value
status
stringclasses
1 value
cpu_time
int64
0
100
memory
stringlengths
4
6
code_size
int64
15
14.7k
code
stringlengths
15
14.7k
problem_id
stringlengths
6
6
problem_description
stringlengths
358
9.83k
input
stringlengths
2
4.87k
output
stringclasses
807 values
__index_level_0__
int64
1.1k
1.22M
s172175223
p04011
u112523623
1527787743
Python
Python (3.4.3)
py
Accepted
18
2940
156
if __name__ == '__main__': n = int(input()) k = int(input()) x = int(input()) y = int(input()) print(min(n, k) * x + max(0, n - k) * y)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,371
s846064567
p04011
u461636820
1527326507
Python
Python (3.4.3)
py
Accepted
17
2940
116
N = int(input()) K = int(input()) X = int(input()) Y = int(input()) print(K * X + (N - K) * Y if N >= K else N * X)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,372
s172131475
p04011
u942871960
1527258352
Python
Python (3.4.3)
py
Accepted
19
2940
166
n = int(input()) k = int(input()) x = int(input()) y = int(input()) sum = 0 for i in range(n): if i < k: sum += x else: sum += y print(sum)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,373
s844314131
p04011
u761320129
1527071592
Python
Python (3.4.3)
py
Accepted
17
2940
76
N,K,X,Y = [int(input()) for i in range(4)] print(min(N,K)*X + max(0,N-K)*Y)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,374
s618724855
p04011
u183481524
1527043977
Python
Python (3.4.3)
py
Accepted
17
2940
132
n = int(input()) k = int(input()) x = int(input()) y = int(input()) if n > k: print(k * x + (n - k) * y) else: print(n * x)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,375
s131177344
p04011
u570612423
1526581127
Python
Python (3.4.3)
py
Accepted
17
3060
153
# -*- coding: utf-8 -*- n = int(input()) k = int(input()) x = int(input()) y = int(input()) if n<k or n==k: print(n*x) else: print(k*x+(n-k)*y)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,376
s180744178
p04011
u047535298
1526501328
Python
Python (3.4.3)
py
Accepted
17
2940
103
n = int(input()) k = int(input()) x = int(input()) y = int(input()) print(min(n, k)*x+max((n-k)*y, 0))
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,377
s202914743
p04011
u399280934
1526413363
Python
Python (3.4.3)
py
Accepted
17
2940
75
n,k,x,y = (int(input()) for _ in range(4)) print(min(n,k)*x + max(0,n-k)*y)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,378
s254658788
p04011
u399280934
1526413190
Python
Python (3.4.3)
py
Accepted
17
2940
114
n=int(input()) k=int(input()) x=int(input()) y=int(input()) if n>=k: print(k*x + (n-k)*y) else: print(n*x)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,379
s510828451
p04011
u132344815
1526341860
Python
Python (3.4.3)
py
Accepted
17
2940
133
N = int(input()) K = int(input()) x = int(input()) y = int(input()) if K >= N: print(N * x) else: print(K * x + (N - K) * y)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,380
s232246609
p04011
u926678805
1526166769
Python
Python (3.4.3)
py
Accepted
17
2940
117
# coding: utf-8 n,k,x,y=int(input()),int(input()),int(input()),int(input()) print(min(k,n)*x+(y*(n-k) if n>k else 0))
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,381
s481638055
p04011
u634208461
1525462015
Python
Python (3.4.3)
py
Accepted
17
2940
127
N = int(input()) K = int(input()) X = int(input()) Y = int(input()) if K >= N: print(N * X) else: print(K * X + (N - K) * Y)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,382
s288850381
p04011
u259752752
1525399053
Python
Python (3.4.3)
py
Accepted
18
2940
249
def cost(N, K, X, Y): cost = 0 for i in range(1,N+1): if i <= K: cost += X else: cost += Y return cost N = int(input()) K = int(input()) X = int(input()) Y = int(input()) print(cost(N, K, X, Y))
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,383
s422220697
p04011
u118019047
1525196460
Python
Python (3.4.3)
py
Accepted
17
3060
179
#宿泊数 n = int(input()) #最初の宿泊数 k = int(input()) #最初の金額 x = int(input()) #以降の金額 y = int(input()) if n < k: k = n print((k*x) + (n-k) * y)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,384
s337127665
p04011
u327248573
1525131143
Python
Python (3.4.3)
py
Accepted
17
2940
148
N = int(input()) K = int(input()) X = int(input()) Y = int(input()) if N <= K: price = N * X else: price = K * X + (N - K) * Y print(price)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,385
s660269249
p04011
u221345507
1525115996
Python
Python (3.4.3)
py
Accepted
17
2940
114
N=int(input()) K=int(input()) X=int(input()) Y=int(input()) if N>=K: print (K*X+(N-K)*Y) else: print (N*X)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,386
s958303538
p04011
u573970531
1524599634
Python
Python (3.4.3)
py
Accepted
17
2940
145
inn = int(input()) ink = int(input()) inx = int(input()) iny = int(input()) if inn <= ink: print(inn*inx) else: print(ink*inx+(inn-ink)*iny)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,387
s189117008
p04011
u040380068
1524509833
Python
Python (2.7.6)
py
Accepted
10
2568
186
def calc(n, k, x, y): if n < k: return n * x else: return k * x + (n-k) * y N = int(raw_input()) K = int(raw_input()) X = int(raw_input()) Y = int(raw_input()) print calc(N, K, X, Y)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,388
s938658453
p04011
u520158330
1524509822
Python
Python (3.4.3)
py
Accepted
19
3060
156
N = int(input()) K = int(input()) X = int(input()) Y = int(input()) SUM = 0 for i in range(1,N+1): if i<=K: SUM += X else: SUM += Y print(SUM)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,389
s295315769
p04011
u826263061
1524446699
Python
Python (3.4.3)
py
Accepted
17
2940
137
n = int(input()) k = int(input()) x = int(input()) y = int(input()) if n <= k: cost = x*n else: cost = x*k + y*(n-k) print(cost)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,390
s877942255
p04011
u218843509
1523748702
Python
Python (3.4.3)
py
Accepted
17
3064
111
N, K, X, Y = [int(input()) for _ in range(4)] if N >= K: print(K * X + (N - K) * Y) else: print(N * X)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,391
s625344228
p04011
u281303342
1523708040
Python
Python (3.4.3)
py
Accepted
17
2940
105
N = int(input()) K = int(input()) X = int(input()) Y = int(input()) print(X*N if N <= K else X*K+Y*(N-K))
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,392
s628005618
p04011
u856232850
1523653922
Python
Python (3.4.3)
py
Accepted
17
2940
119
a = int(input()) b = int(input()) c = int(input()) d = int(input()) if a>b: print(b*c+(a-b)*d) else: print(a*c)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,393
s267360353
p04011
u226108478
1523637097
Python
Python (3.4.3)
py
Accepted
17
2940
276
# -*- coding: utf-8 -*- # AtCoder Beginner Contest # Problem A if __name__ == '__main__': n = int(input()) k = int(input()) x = int(input()) y = int(input()) diff = n - k if diff > 0: print((k * x) + diff * y) else: print(n * x)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,394
s968121351
p04011
u766407523
1523385296
Python
Python (3.4.3)
py
Accepted
17
2940
131
def inpn(): return int(input()) N, K, X, Y = inpn(), inpn(), inpn(), inpn() if N <= K: print(N*X) else: print(K*X+(N-K)*Y)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,395
s131477515
p04011
u306142032
1522874451
Python
Python (3.4.3)
py
Accepted
17
2940
126
n = int(input()) k = int(input()) x = int(input()) y = int(input()) if n >= k: print(k*x + (n-k)*y) else: print(n*x)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,396
s214017592
p04011
u058580040
1522669120
Python
Python (3.4.3)
py
Accepted
17
3060
355
import sys import io def run(input: io.TextIOBase, output: io.TextIOBase): n = int(input.readline()) k = int(input.readline()) x = int(input.readline()) y = int(input.readline()) if n < k: r = n*x else: r = k*x+(n-k)*y output.write(str(r) + '\n') if __name__ == '__main_...
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,397
s206748888
p04011
u461636820
1522296240
Python
Python (3.4.3)
py
Accepted
17
2940
128
n = int(input()) k = int(input()) x = int(input()) y = int(input()) if n - k < 0: print(n*x) else: print(k * x + (n - k) * y)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,398
s964086495
p04011
u200239931
1522203455
Python
Python (3.4.3)
py
Accepted
18
3064
668
import math import sys def getinputdata(): # 配列初期化 array_result = [] data = input() array_result.append(data.split(" ")) flg = 1 try: while flg: data = input() array_temp = [] if(data != ""): array_r...
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,399
s786854833
p04011
u027622859
1522119959
Python
Python (3.4.3)
py
Accepted
17
2940
130
n = int(input()) k = int(input()) x = int(input()) y = int(input()) if k < n: print((n*x) + (n-k)*(y-x)) else: print(n*x)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,400
s497731070
p04011
u985076807
1522093385
Python
Python (3.4.3)
py
Accepted
17
2940
152
# coding: utf-8 n = int(input()) k = int(input()) x = int(input()) y = int(input()) if n - k < 0: print(n * x) else: print(k * x + (n - k) * y)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,401
s959869790
p04011
u479060428
1522083819
Python
Python (3.4.3)
py
Accepted
17
2940
114
N=int(input()) K=int(input()) X=int(input()) Y=int(input()) if N<=K : print(X*N) else : print(X*K+Y*(N-K))
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,402
s720378197
p04011
u158566391
1521991771
Python
Python (3.4.3)
py
Accepted
17
3064
112
n=int(input()) k=int(input()) x=int(input()) y=int(input()) a=0 if n-k>=0: print(k*x+(n-k)*y) else: print(n*x)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,403
s972257646
p04011
u729707098
1521927303
Python
Python (3.4.3)
py
Accepted
17
2940
98
n = int(input()) k = int(input()) x = int(input()) y = int(input()) print(x*min(n,k)+y*max(n-k,0))
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,404
s853415886
p04011
u127856129
1521472674
Python
Python (3.4.3)
py
Accepted
20
2940
128
a=int(input()) b=int(input()) c=int(input()) d=int(input()) if a>=b: print(int((b*c)+((a-b)*d))) else: print(int(a*c))
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,405
s643862005
p04011
u391475811
1521419884
Python
Python (3.4.3)
py
Accepted
17
2940
109
N=int(input()) K=int(input()) X=int(input()) Y=int(input()) if N>K: print(K*X+(N-K)*Y) else: print(N*X)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,406
s841657554
p04011
u773981351
1521204690
Python
Python (2.7.6)
py
Accepted
10
2568
145
n = int(raw_input()) k = int(raw_input()) x = int(raw_input()) y = int(raw_input()) print min(k, n) * x + (n - k) * y if n > k else min(k, n) * x
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,407
s194059354
p04011
u653005308
1521168445
Python
Python (3.4.3)
py
Accepted
17
2940
112
n=int(input()) k=int(input()) x=int(input()) y=int(input()) if n<=k: print(n*x) else: print(k*x+(n-k)*y)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,408
s114490843
p04011
u562016607
1521147307
Python
Python (3.4.3)
py
Accepted
17
2940
109
N=int(input()) K=int(input()) X=int(input()) Y=int(input()) if K<=N: print(K*X+(N-K)*Y) else: print(X*N)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,409
s125925240
p04011
u941884460
1520876116
Python
Python (3.4.3)
py
Accepted
19
3060
155
N = int(input()) K = int(input()) X = int(input()) Y = int(input()) sum = 0 for i in range(1,N+1): if i <=K: sum += X else: sum += Y print(sum)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,410
s925342532
p04011
u898651494
1520762199
Python
Python (3.4.3)
py
Accepted
17
2940
121
n = int(input()) k = int(input()) x = int(input()) y = int(input()) if k >= n : print(n*x) else: print((n-k)*y +k*x)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,411
s856465499
p04011
u632369368
1520754524
Python
Python (3.4.3)
py
Accepted
17
2940
116
N = int(input()) K = int(input()) X = int(input()) Y = int(input()) V = X * min(N, K) + Y * max(N - K, 0) print(V)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,412
s783062446
p04011
u597436499
1519923767
Python
Python (3.4.3)
py
Accepted
17
2940
134
n = int(input()) k = int(input()) x = int(input()) y = int(input()) if n >= k: print(k * x + (n - k) * y) else: print(n * x)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,413
s448189722
p04011
u858136677
1519589374
Python
Python (3.4.3)
py
Accepted
17
2940
115
n = int(input()) k = int(input()) x = int(input()) y = int(input()) if n > k: print(k*x+(n-k)*y) else: print(n*x)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,414
s464614908
p04011
u601913978
1519372687
Python
Python (3.4.3)
py
Accepted
17
2940
137
n = int(input()) k = int(input()) x = int(input()) y = int(input()) if n - k > 0: print(k * x + (n - k) * y) else: print(n * x)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,415
s692441982
p04011
u597436499
1519353600
Python
Python (3.4.3)
py
Accepted
17
2940
134
n = int(input()) k = int(input()) x = int(input()) y = int(input()) if n >= k: print(k * x + (n - k) * y) else: print(n * x)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,416
s027915411
p04011
u621935300
1519179782
Python
Python (2.7.6)
py
Accepted
12
2948
111
N=input() K=input() X=input() Y=input() ans=0 for i in range(N): if i<=K-1: ans+=X else: ans+=Y print ans
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,417
s997567232
p04011
u319612498
1518933084
Python
Python (3.4.3)
py
Accepted
17
2940
96
n, k, x, y=(int(input()) for i in range(4)) if n<=k: print(n*x) else: print(k*x+(n-k)*y)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,418
s231430768
p04011
u030726788
1518903376
Python
Python (3.4.3)
py
Accepted
17
2940
110
N=int(input()) K=int(input()) X=int(input()) Y=int(input()) if(N<=K): print(X*N) else: print(X*K+Y*(N-K))
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,419
s572668464
p04011
u030726788
1518903362
Python
Python (3.4.3)
py
Accepted
17
2940
108
N=int(input()) K=int(input()) X=int(input()) Y=int(input()) if(N<=K): print(X*N) else: print(X*K+Y*(N-K))
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,420
s568212616
p04011
u019584841
1518815158
Python
Python (3.4.3)
py
Accepted
18
2940
89
n,k,x,y=(int(input()) for _ in range(4)) if n<=k: print(n*x) else: print(k*x+(n-k)*y)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,421
s769996378
p04011
u875361824
1518431315
Python
Python (3.4.3)
py
Accepted
17
2940
196
def main(): N = int(input()) K = int(input()) X = int(input()) Y = int(input()) ans = X * min(K, N) + Y * max(N - K, 0) print(ans) if __name__ == '__main__': main()
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,422
s682466494
p04011
u764600134
1518362000
Python
Python (3.4.3)
py
Accepted
17
3064
496
# -*- coding: utf-8 -*- """ https://beta.atcoder.jp/contests/abc044/tasks/abc044_a """ import sys from sys import stdin input = stdin.readline def solve(N, K, X, Y): total = 0 if N > K: total += X * K total += Y * (N - K) else: total += X * N return total def main(args): ...
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,423
s161909031
p04011
u952708174
1517120485
Python
Python (3.4.3)
py
Accepted
17
2940
119
N = int(input()) K = int(input()) X = int(input()) Y = int(input()) if N<=K: print(X*N) else: print(X*K+Y*(N-K))
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,424
s827440836
p04011
u103539599
1517002312
Python
Python (3.4.3)
py
Accepted
17
2940
113
N=int(input()) K=int(input()) X=int(input()) Y=int(input()) if N>K: print(K*X+(N-K)*Y) else: print(N*X)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,425
s205327127
p04011
u498401785
1516755396
Python
Python (3.4.3)
py
Accepted
20
2940
128
n=int(input()) k=int(input()) x=int(input()) y=int(input()) f=0 for i in range(n): if(i<k): f+=x else: f+=y print(f)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,426
s850690170
p04011
u743272507
1516744365
Python
Python (3.4.3)
py
Accepted
17
2940
123
n = int(input()) k = int(input()) x = int(input()) y = int(input()) if n <= k: print(n*x) else: print(k*x+(n-k)*y)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,427
s534479859
p04011
u202877219
1516585088
Python
Python (3.4.3)
py
Accepted
19
3316
158
n = int(input()) k = int(input()) x = int(input()) y = int(input()) z = 0 for i in range(n): if i >= k: z += y else: z += x print (z)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,428
s685718149
p04011
u254456372
1516485032
Python
Python (3.4.3)
py
Accepted
18
2940
233
#!/usr/bin/env python3 # -*- coding: utf-8 -*- def main(): N = int(input()) K = int(input()) X = int(input()) Y = int(input()) ans = X*min(N,K) + Y*max(N-K,0) print(ans) if __name__ == "__main__": main()
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,429
s735872906
p04011
u811528179
1515561447
Python
Python (3.4.3)
py
Accepted
18
2940
71
n,k,x,y=[int(input()) for _ in range(4)] print([k*x+(n-k)*y,n*x][k>n])
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,430
s037378246
p04011
u124843595
1515412043
Python
Python (3.4.3)
py
Accepted
18
2940
82
n,k,x,y=[int(input()) for _ in range(4)] print(x*k+y*(n-k)) if n>k else print(x*n)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,431
s948609546
p04011
u136090046
1515115159
Python
Python (3.4.3)
py
Accepted
17
2940
106
N = int(input()) K = int(input()) X = int(input()) Y = int(input()) print(N*X if K >= N else K*X+(N-K)*Y)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,432
s566433652
p04011
u586577600
1514859384
Python
Python (3.4.3)
py
Accepted
17
2940
101
n, k, x, y = [int(input()) for i in range(4)] if n <= k: print(x*n) else: print(x*k + max(0, n-k)*y)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,433
s363185893
p04011
u057463552
1514347225
Python
Python (3.4.3)
py
Accepted
18
3064
253
N = int(input()) K = int(input()) X = int(input()) Y = int(input()) sum = 0 if N <= K: for i in range(0,N): sum = sum + X if N >= K + 1: for i in range(0,K): sum = sum + X for i in range(K,N): sum = sum + Y print(sum)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,434
s479725430
p04011
u636684559
1514245462
Python
Python (3.4.3)
py
Accepted
23
3060
138
N=input() K=input() X=input() Y=input() ans=0 for i in range(int(N)): if i+1<=int(K): ans+=int(X) else: ans+=int(Y) print(ans)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,435
s692149980
p04011
u854627522
1514233967
Python
Python (3.4.3)
py
Accepted
17
2940
131
n = int(input()) k = int(input()) x = int(input()) y = int(input()) if n>=k: print(k * x + (n - k) * y) else: print(x * n)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,436
s046607995
p04011
u550574002
1514170996
Python
Python (3.4.3)
py
Accepted
17
2940
74
N,K,X,Y = [int(input()) for i in range(4)] print(N*X - max(0,(N-K)*(X-Y)))
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,437
s869192265
p04011
u867069435
1514170678
Python
Python (3.4.3)
py
Accepted
17
2940
104
n = int(input()) k = int(input()) x = int(input()) y = int(input()) print(min(n, k)*x + max(n-k, 0) * y)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,438
s414532010
p04011
u558836062
1514004010
Python
Python (3.4.3)
py
Accepted
17
2940
128
N = int(input()) K = int(input()) X = int(input()) Y = int(input()) if N > K: print(K * X + (N - K)* Y) else: print(N * X)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,439
s031845265
p04011
u204230270
1513882432
Python
Python (3.4.3)
py
Accepted
17
3060
131
n = int(input()) k = int(input()) x = int(input()) y = int(input()) i = n - k if i > 0: print(k * x + y * i) else: print(n * x)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,440
s152385830
p04011
u853586331
1513881254
Python
Python (3.4.3)
py
Accepted
17
2940
107
N=int(input()) K=int(input()) x=int(input()) y=int(input()) if K>=N: print(N*x) else: print(K*x+(N-K)*y)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,441
s647991770
p04011
u355798276
1513258323
Python
Python (3.4.3)
py
Accepted
17
2940
135
N = int(input()) K = int(input()) X = int(input()) Y = int(input()) if N <= K: print(X * N) else: print(X * K + (N - K) * Y)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,442
s119457165
p04011
u257974487
1513053275
Python
Python (3.4.3)
py
Accepted
17
2940
123
N = int(input()) K = int(input()) X = int(input()) Y = int(input()) if N > K: print(K*X + (N-K)*Y) else: print(N*X)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,443
s437719364
p04011
u825528847
1512841833
Python
Python (3.4.3)
py
Accepted
17
2940
105
N = int(input()) K = int(input()) X = int(input()) Y = int(input()) print(min(K, N)*X + max(0, N-K) * Y)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,444
s563827800
p04011
u003006319
1512810220
Python
Python (3.4.3)
py
Accepted
17
2940
106
N=int(input()) K=int(input()) X=int(input()) Y=int(input()) if N>=K: print(K*X+(N-K)*Y) else: print(N*X)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,445
s840683781
p04011
u136869985
1512600796
Python
Python (3.4.3)
py
Accepted
19
3060
281
def main(): N = int(input()) K = int(input()) X = int(input()) Y = int(input()) total = 0 for x in range(1, N + 1): if x <= K: total += X else: total += Y print(total) if __name__ == "__main__": main()
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,446
s638428003
p04011
u813450984
1511546852
Python
Python (3.4.3)
py
Accepted
18
2940
128
n = int(input()) k = int(input()) x = int(input()) y = int(input()) if n > k: print(x * k + y * (n - k)) else: print(n * x)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,447
s078592488
p04011
u667024514
1511108345
Python
Python (3.4.3)
py
Accepted
17
2940
116
N = int(input()) K = int(input()) X = int(input()) Y = int(input()) if N >= K: print(K*X+(N-K)*Y) else: print(N*X)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,448
s120346850
p04011
u075012704
1511022936
Python
Python (3.4.3)
py
Accepted
18
2940
103
N = int(input()) K = int(input()) X = int(input()) Y = int(input()) print(min(K,N)*X + max((N-K),0)*Y)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,449
s124419408
p04011
u451017206
1510367452
Python
Python (3.4.3)
py
Accepted
17
2940
110
N = int(input()) K = int(input()) X = int(input()) Y = int(input()) print(min(N, K) * X + max(0,(N - K)) * Y)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,450
s616245518
p04011
u665415433
1509660026
Python
Python (3.4.3)
py
Accepted
17
2940
112
n = int(input()) k = int(input()) x = int(input()) y = int(input()) print(min(k, n) * x + max(0, (n - k)) * y)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,451
s774628807
p04011
u561422857
1509591530
Python
Python (3.4.3)
py
Accepted
19
2940
173
N = int(input()) K = int(input()) X = int(input()) Y = int(input()) num = 0 for i in range(N): if (i + 1) > K: num += Y else: num += X print(num)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,452
s431877499
p04011
u781025961
1509052139
Python
Python (3.4.3)
py
Accepted
20
2940
131
N = int(input()) K = int(input()) X = int(input()) Y = int(input()) if K >= N: print(X * N) else: print(X * K + Y * (N-K))
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,453
s381652919
p04011
u252745826
1508333467
Python
Python (3.4.3)
py
Accepted
18
2940
130
N = int(input()) K = int(input()) X = int(input()) Y = int(input()) if N > K: print(K * X + (N-K) * Y) else: print(N * X)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,454
s055435399
p04011
u425351967
1508163986
Python
Python (3.4.3)
py
Accepted
18
2940
103
N = int(input()) K = int(input()) X = int(input()) Y = int(input()) print(X*min(K, N) + Y*max(0, N-K))
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,455
s483823650
p04011
u190405389
1507685329
Python
Python (3.4.3)
py
Accepted
17
3064
101
n = int(input()) k = int(input()) x = int(input()) y = int(input()) print(min(n, k)*x+max(n-k, 0)*y)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,456
s116035458
p04011
u785205215
1507445150
Python
Python (3.4.3)
py
Accepted
17
3064
639
from sys import stdin, stdout def readLine_int_list():return list(map(int, stdin.readline().split())) def readLine_int_list_reverse(): return list(map(int, stdin.readline().split())).reverse() def readAll_int(): return list(map(int, stdin)) def readLine_str_list():return list(map(str, stdin.readline().split())) def rea...
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,457
s990270632
p04011
u559651225
1506804419
Python
Python (2.7.6)
py
Accepted
11
2568
92
n = input() k = input() x = input() y = input() ans = n*x + (y - x) * max(n-k, 0) print ans
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,458
s943621856
p04011
u663710122
1506619181
Python
Python (3.4.3)
py
Accepted
18
2940
110
N = int(input()) K = int(input()) X = int(input()) Y = int(input()) print(min(N, K) * X + max(N - K, 0) * Y)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,459
s556436947
p04011
u772180901
1505932248
Python
Python (3.4.3)
py
Accepted
18
3060
163
n = int(input()) k = int(input()) x = int(input()) y = int(input()) ans = 0 for i in range(n): if i < k: ans += x else: ans += y print(ans)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,460
s349768749
p04011
u598016178
1505683087
Python
Python (3.4.3)
py
Accepted
17
2940
66
n,k,x,y=[int(input())for _ in[0]*4];print(min(n,k)*x+max(0,n-k)*y)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,461
s757150547
p04011
u598016178
1505682855
Python
Python (3.4.3)
py
Accepted
17
2940
74
a=[int(input())for i in[0]*4];print(min(a[:2])*a[2]+max(0,a[0]-a[1])*a[3])
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,462
s053318934
p04011
u598016178
1505682404
Python
Python (3.4.3)
py
Accepted
17
2940
78
a=[int(input())for i in[0]*4];print(min(a[0],a[1])*a[2]+max(0,a[0]-a[1])*a[3])
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,463
s661685675
p04011
u598016178
1505676385
Python
Python (3.4.3)
py
Accepted
17
2940
109
n = int(input()) k = int(input()) x = int(input()) y = int(input()) print(min(n, k) * x + max(0, n - k) * y)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,464
s198048451
p04011
u525441048
1505642839
Python
Python (3.4.3)
py
Accepted
18
2940
162
N = int(input()) K = int(input()) X = int(input()) Y = int(input()) A = 0 for i in range(1, N+1): if i <= K: A += X else: A += Y print(A)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,465
s209850454
p04011
u261886891
1505514479
Python
Python (3.4.3)
py
Accepted
17
3060
112
N = int(input()) K = int(input()) X = int(input()) Y = int(input()) a = min(K, N) b = max(N-K, 0) print(a*X+b*Y)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,466
s226760423
p04011
u367393577
1505102470
Python
Python (3.4.3)
py
Accepted
17
2940
134
n = int(input()) k = int(input()) x = int(input()) y = int(input()) if n <= k: print(n * x) else: print(k * x + (n - k) * y)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,467
s160699726
p04011
u182096840
1504458202
Python
Python (2.7.6)
py
Accepted
10
2568
161
n = int(raw_input()) k = int(raw_input()) x = int(raw_input()) y = int(raw_input()) total = 0 if n <= k: total += n*x else: total += k*x + (n-k)*y print(total)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,468
s601044551
p04011
u778700306
1503849966
Python
Python (3.4.3)
py
Accepted
17
2940
100
N, K, X, Y = [int(input()) for _ in range(4)] res = min(K, N) * X + max(0, N - K) * Y print(res)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,469
s847450832
p04011
u778700306
1503849813
Python
Python (3.4.3)
py
Accepted
17
3060
147
N = int(input()) K = int(input()) X = int(input()) Y = int(input()) O = max(0, N - K) # over P = N - O # res = P * X + O * Y print(res)
p04011
<span class="lang-en"> <p>Score : <var>100</var> points</p> <div class="part"> <section> <h3>Problem Statement</h3><p>There is a hotel with the following accommodation fee:</p> <ul> <li><var>X</var> yen (the currency of Japan) per night, for the first <var>K</var> nights</li> <li><var>Y</var> yen per night, for the <va...
5 3 10000 9000
48000
1,197,470