Search is not available for this dataset
name
stringlengths 2
88
| description
stringlengths 31
8.62k
| public_tests
dict | private_tests
dict | solution_type
stringclasses 2
values | programming_language
stringclasses 5
values | solution
stringlengths 1
983k
|
---|---|---|---|---|---|---|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | java | import java.util.*;
class Main{
public static void main(String args[]){
Scanner sc=new Scanner(System.in);
for(int i=0;i<4;i++){
int t,n;
t=sc.nextInt();
n=sc.nextInt();
if(t==1){
System.out.println(6000*n);
}else if(t==2){
System.out.println(4000*n);
}else if(t==3){
System.out.println(3000*n);
}else{
System.out.println(2000*n);
}
}
}
}
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | python3 | list=[]
for i in range(4):
t,n=map(int,input().split())
if t==1:
print(6000*n)
elif t==2:
print(4000*n)
elif t==3:
print(3000*n)
elif t==4:
print(2000*n)
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | python3 | for _ in range(4):
t,n = map(int,input().split())
if t == 1:
print(6000*n)
elif t == 2:
print(4000*n)
elif t == 3:
print(3000*n)
elif t == 4:
print(2000*n)
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | java | import java.util.Scanner;
public class Main{
Scanner sc=new Scanner(System.in);
int n,m;
void a(){
for(int i=0; i<4; i++){
n=sc.nextInt();
m=sc.nextInt();
if(n==1){
System.out.println(6000*m);
}else if(n==2){
System.out.println(4000*m);
}else if(n==3){
System.out.println(3000*m);
}else if(n==4){
System.out.println(2000*m);
}
}
}
public static void main(String[]agrs){
new Main().a();
}
}
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | python3 | for _ in range(4):
a,b = map(int,input().split()) #標準入力
if a == 1:print(b * 6000) #s席なら6000をかける
if a == 2:print(b * 4000) #A席なら4000をかける
if a == 3:print(b * 3000) #B席なら3000をかける
if a == 4:print(b * 2000) #C席なら2000をかける
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include<iostream>
int main()
{
int value[] = {0, 6000, 4000, 3000, 2000};
for(int i = 0; i < 4; i++)
{
int a, b;
std::cin >> a >> b;
std::cout << value[a] * b << std::endl;
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include<stdio.h>
int main(void)
{
int a,b,c,d,t,i;
for(i=1;i<=4;i++){
scanf("%d %d",&a,&b);
if(a==1){
a=6000;
}
else if(a==2){
a=4000;
}
else if(a==3){
a=3000;
}
else if(a==4){
a=2000;
}
c=a*b;
printf("%d\n",c);
}
return 0;
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | python3 | t1,n1 = map(int,input().split())
t2,n2 = map(int,input().split())
t3,n3 = map(int,input().split())
t4,n4 = map(int,input().split())
if t1==1:
print(n1*6000)
if t2==2:
print(n2*4000)
if t3==3:
print(n3*3000)
print(n4*2000)
if t3==4:
print(n3*2000)
print(n4*3000)
if t2==3:
print(n2*3000)
if t3==2:
print(n3*4000)
print(n4*2000)
if t3==4:
print(n3*2000)
print(n4*4000)
if t2==4:
print(n2*2000)
if t3==2:
print(n3*4000)
print(n4*3000)
if t3==3:
print(n3*3000)
print(n4*4000)
if t1==2:
print(n1*4000)
if t2==1:
print(n2*6000)
if t3==3:
print(n3*3000)
print(n4*2000)
if t3==4:
print(n3*2000)
print(n4*3000)
if t2==3:
print(n2*3000)
if t3==1:
print(n3*6000)
print(n4*2000)
if t3==4:
print(n3*2000)
print(n4*6000)
if t2==4:
print(n2*2000)
if t3==1:
print(n3*6000)
print(n4*3000)
if t3==3:
print(n3*3000)
print(n4*6000)
if t1==3:
print(n1*3000)
if t2==1:
print(n2*6000)
if t3==2:
print(n3*4000)
print(n4*2000)
if t3==4:
print(n3*2000)
print(n4*4000)
if t2==2:
print(n2*4000)
if t3==1:
print(n3*6000)
print(n4*2000)
if t3==4:
print(n3*2000)
print(n4*6000)
if t2==4:
print(n2*2000)
if t3==1:
print(n3*6000)
print(n4*3000)
if t3==3:
print(n3*3000)
print(n4*6000)
if t1==4:
print(n1*2000)
if t2==1:
print(n2*6000)
if t3==2:
print(n3*4000)
print(n4*3000)
if t3==3:
print(n3*3000)
print(n4*4000)
if t2==2:
print(n2*4000)
if t3==1:
print(n3*6000)
print(n4*3000)
if t3==3:
print(n3*3000)
print(n4*6000)
if t2==3:
print(n2*3000)
if t3==1:
print(n3*6000)
print(n4*4000)
if t3==2:
print(n3*4000)
print(n4*6000)
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | python3 | # AOJ 0277: Ticket Sales
# Python3 2018.6.23 bal4u
ticket = {1:6000, 2:4000, 3:3000, 4:2000}
for i in range(4):
t, n = map(int, input().split())
print(n*ticket[t])
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | python3 | i = 1
while i <= 4:
t,n =map(int,input().split())
if t ==1:
n1 = n * 6000
print(n1)
elif t == 2:
n2 = n * 4000
print(n2)
elif t == 3:
n3 = n*3000
print(n3)
else:
n4 = n*2000
print(n4)
i += 1
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | python3 | i=1
while i<=4:
t,n = map(int,input().split())
i += 1
if t == 1: print(6000*n)
elif t == 2: print(4000*n)
elif t == 3: print(3000*n)
else: print(2000*n)
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include <cstdio>
#include <cstdlib>
#include <vector>
#include <iostream>
#include <algorithm>
using namespace std;
int main(){
int p[5] = {0,6000,4000,3000,2000};
int a,b,ans=0;
for(int i=0;i<4;i++){
scanf("%d%d",&a,&b);
cout << b * p[a] << endl;
}
return 0;
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | python3 | t1, n1= map(int, input(). split())
t2, n2= map(int, input(). split())
t3, n3= map(int, input(). split())
t4, n4= map(int, input(). split())
i = 1
while i <= 4:
if t1== 1:
t1 = 6000
elif t1 == 2:
t1 = 4000
elif t1 == 3:
t1 = 3000
elif t1 == 4:
t1 = 2000
elif t2 == 1:
t2 = 6000
elif t2 == 2:
t2 = 4000
elif t2 == 3:
t2 = 3000
elif t2 == 4:
t2 = 2000
elif t3 == 1:
t3 = 6000
elif t3 == 2:
t3 = 4000
elif t3 == 3:
t3 = 3000
elif t3 == 4:
t3 = 2000
elif t4 == 1:
t4 = 6000
elif t4 == 2:
t4 = 4000
elif t4 == 3:
t4 = 3000
elif t4 == 4:
t4 = 2000
i += 1
print(t1*n1)
print(t2*n2)
print(t3*n3)
print(t4*n4)
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | java | import java.util.*;
public class Main {
public static void main(String[] args) {
Scanner in =new Scanner(System.in);
int P[]={6000,4000,3000,2000};
for(int i=0;i<4;i++){
int j=in.nextInt(),k=in.nextInt();
System.out.println(P[j-1]*k);
}
}
}
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include<iostream>
#include<algorithm>
using namespace std;
int a[4]={6000,4000,3000,2000};
int main(void){
int t,n;
while(cin >> t >> n){
cout << a[t-1]*n << endl;
}
return 0;
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | python3 | d = {1:6000, 2:4000, 3:3000, 4:2000}
for i in range(4) :
t,n = map(int,input().split())
print(d[t]*n)
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | python3 | costs = []
for _ in range(0, 4):
i, v = map(int, input().split())
if i == 1:
costs.append(6000*v)
elif i == 2:
costs.append(4000*v)
elif i == 3:
costs.append(3000*v)
elif i == 4:
costs.append(2000*v)
for cost in costs:
print(cost)
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include <stdio.h>
int main(){
int a,b,c,i;
for(i=1;i<=4;i++){
scanf("%d %d",&a,&b);
if(a==1){
c=6000*b;
}else if(a==2){
c=4000*b;
}else if(a==3){
c=3000*b;
}else if(a==4){
c=2000*b;
}
printf("%d\n",c);
}
return 0;
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include <iostream>
using namespace std;
int main(){
int dat[4] = {6, 4, 3, 2}, a, b;
while(cin >> a >> b) cout << dat[a-1] * b * 1000 << endl;
return 0;
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | java | import java.util.Scanner;
public class Main {
public static void main(String[] args){
Scanner sc=new Scanner(System.in);
int t,n;
int[] p = {0,6,4,3,2};
for(int i=0;i<4;i++){
t=sc.nextInt();
n=sc.nextInt();
System.out.println(p[t]*n*1000);
}
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include <iostream>
using namespace std;
int main(void){
for(int i = 0;i < 4; i++){
int t,n;
cin>>t>>n;
if(t == 1)cout<<6000*n<<endl;
if(t == 2)cout<<4000*n<<endl;
if(t == 3)cout<<3000*n<<endl;
if(t == 4)cout<<2000*n<<endl;
}
}
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include <iostream>
using namespace std;
int main() {
int t, n;
for(int i = 0; i < 4; i++) {
cin >> t >> n;
if(t == 1) {
cout << 6000 * n << std::endl;
}
if(t == 2) {
cout << 4000 * n << std::endl;
}
if(t == 3) {
cout << 3000 * n << std::endl;
}
if(t == 4) {
cout << 2000 * n << std::endl;
}
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include <cstdio>
int a, t, b[] = {6000, 4000, 3000, 2000};
int main(){
for(int i = 0; i < 4; i++){
scanf("%d %d", &a, &t);
printf("%d\n", b[a - 1] * t);
}
return 0;
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include<stdio.h>
int main(void)
{
int a,b,x[5],i;
for(i=0;i<4;i++){
a=0; b=0;
scanf("%d %d",&a,&b);
if(a==1) x[i]=b*6000;
if(a==2) x[i]=b*4000;
if(a==3) x[i]=b*3000;
if(a==4) x[i]=b*2000;
}
for(i=0;i<4;i++) printf("%d\n",x[i]);
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | python3 | a,n1=map(int,input().split())
b,n2=map(int,input().split())
c,n3=map(int,input().split())
d,n4=map(int,input().split())
t1=6000
t2=4000
t3=3000
t4=2000
if a==1:
if b==2:
if c==3:
print(t1*n1)
print(t2*n2)
print(t3*n3)
print(t4*n4)
else:
print(t1*n1)
print(t2*n2)
print(t4*n3)
print(t3*n4)
elif b==3:
if c==2:
print(t1*n1)
print(t3*n2)
print(t2*n3)
print(t4*n4)
else:
print(t1*n1)
print(t3*n2)
print(t4*n3)
print(t2*n4)
else:
if c==2:
print(t1*n1)
print(t4*n2)
print(t2*n3)
print(t3*n4)
else:
print(t1*n1)
print(t4*n2)
print(t3*n3)
print(t2*n4)
elif a==2:
if b==1:
if c==3:
print(t2*n1)
print(t1*n2)
print(t3*n3)
print(t4*n4)
else:
print(t2*n1)
print(t1*n2)
print(t4*n3)
print(t3*n4)
elif b==3:
if c==1:
print(t2*n1)
print(t3*n2)
print(t1*n3)
print(t4*n4)
else:
print(t2*n1)
print(t3*n2)
print(t4*n3)
print(t1*n4)
else:
if c==1:
print(t2*n1)
print(t4*n2)
print(t1*n3)
print(t3*n4)
else:
print(t2*n1)
print(t4*n2)
print(t3*n3)
print(t*n4)
elif a==3:
if b==1:
if c==2:
print(t3*n1)
print(t1*n2)
print(t2*n3)
print(t4*n4)
else:
print(t3*n1)
print(t1*n2)
print(t4*n3)
print(t2*n4)
elif b==2:
if c==1:
print(t3*n1)
print(t2*n2)
print(t1*n3)
print(t4*n4)
else:
print(t3*n1)
print(t2*n2)
print(t4*n3)
print(t1*n4)
else:
if c==1:
print(t3*n1)
print(t4*n2)
print(t1*n3)
print(t2*n4)
else:
print(t3*n1)
print(t4*n2)
print(t2*n3)
print(t1*n4)
else:
if b==1:
if c==2:
print(t4*n1)
print(t1*n2)
print(t2*n3)
print(t3*n4)
else:
print(t4*n1)
print(t1*n2)
print(t3*n3)
print(t2*n4)
elif b==2:
if c==1:
print(t4*n1)
print(t2*n2)
print(t1*n3)
print(t3*n4)
else:
print(t4*n1)
print(t2*n2)
print(t3*n3)
print(t1*n4)
else:
if c==1:
print(t4*n1)
print(t3*n2)
print(t1*n3)
print(t2*n4)
else:
print(t3*n1)
print(t3*n2)
print(t2*n3)
print(t1*n4)
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | //PCK2015予選4
#include<iostream>
using namespace std;
int main(){
int t[4] = {6,4,3,2};
for(int i=0;i<4;++i){
int n,m;
cin>>n>>m;
cout<<t[n-1]*m*1000<<endl;
}
}
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include <iostream>
using namespace std;
int my[] = {6000, 4000, 3000, 2000};
int main()
{
int n, m;
for (int i = 0; i < 4; i++){
cin >> n >> m;
cout << my[n - 1] * m << endl;
}
return (0);
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include <bits/stdc++.h>
using namespace std;
const int table[] = {-1, 6000, 4000, 3000, 2000};
int main()
{
for (int i = 0; i < 4; i++){
int t, n;
scanf("%d %d", &t, &n);
printf("%d\n", table[t] * n);
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include <iostream>
using namespace std;
// http://judge.u-aizu.ac.jp/onlinejudge/description.jsp?id=0277
int main() {
int arr[4];
int prices[] = { 6000, 4000, 3000, 2000 };
for (int i = 0; i < 4; i++) {
int t, n;
cin >> t >> n;
cout << (prices[t - 1] * n) << endl;
}
return 0;
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | java | import java.util.Scanner;
public class Main {
Scanner sc = new Scanner(System.in);
int kingaku;
int[] goukei = new int[4];
int n;
public void syurui(){
for (n = 0; n <= 3;n++){
int syurui = sc.nextInt();
int maisuu = sc.nextInt();
switch(syurui){
case 1: kingaku = 6000;break;
case 2: kingaku = 4000;break;
case 3: kingaku = 3000;break;
case 4: kingaku = 2000;break;
}
goukei[n] = kingaku * maisuu;}
}
public void hyouji(){
for(n = 0; n <= 3; n++){
System.out.println(goukei[n]);
}
}
public static void main(String[] args) {
Main m = new Main();
m.syurui();
m.hyouji();
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include <iostream>
using namespace std;
using ll = long long;
ll table[] = {0, 6000, 4000, 3000, 2000};
int main()
{
ll t, n;
for (int i = 0; i < 4; i++) {
cin >> t >> n;
cout << table[t] * n << endl;
}
return 0;
}
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include <iostream>
using namespace std;
int main(void){
int t,n;
for(int i = 0; i < 4; i++){
cin >> t >> n;
if(t == 1)cout << n*6000 << endl;
if(t == 2)cout << n*4000 << endl;
if(t == 3)cout << n*3000 << endl;
if(t == 4)cout << n*2000 << endl;
}
}
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include<iostream>
#include<string>
using namespace std;
int main(){
int b[4], c[4];
for (int i = 0; i < 4; i++){
cin >> b[i] >> c[i];
}
for (int i = 0; i < 4; i++){
if (b[i] == 1){ cout << 6000 * c[i] << endl; }
else
{cout << (6-b[i])*1000 * c[i] << endl;}
}
return 0;
}
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | python2 | t=[6000,4000,3000,2000]
for i in xrange(4):
l=map(int,raw_input().split())
print l[1]*t[l[0]-1] |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | java | import java.util.Scanner;
class Main{
public static void main(String[] args) {
Scanner sc=new Scanner(System.in);
while(sc.hasNextInt()){
int t=sc.nextInt();
int n=sc.nextInt();
int S=1;
int A=2;
int B=3;
int C=4;
int ans=0;
if(t==S){
ans=6000*n;
} if(t==A){
ans=4000*n;
} if(t==B){
ans=3000*n;
} if(t==C){
ans=n*2000;
}
System.out.println(ans);
}
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | java | import java.util.*;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int []value ={6000,4000,3000,2000};
int []ans;
for(int i=0; i<4; i++){
int t=sc.nextInt()-1;
int n=sc.nextInt();
System.out.println(value[t]*n);
}
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | python3 | def change(t) :
if t == 1 :
return 6000
elif t == 2 :
return 4000
elif t == 3 :
return 3000
elif t == 4 :
return 2000
t1, n1 = map(int, input().split())
t2, n2 = map(int, input().split())
t3, n3 = map(int, input().split())
t4, n4 = map(int, input().split())
print(change(t1) * n1)
print(change(t2) * n2)
print(change(t3) * n3)
print(change(t4) * n4)
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | python3 | a={1:6000,2:4000,3:3000,4:2000}
for i in range(4):
t, n=map(int,input().split())
print(n*a[t])
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include<iostream>
using namespace std;
int main(){
int i, y;
int a[4] = {6000, 4000, 3000, 2000};
while(cin >> i >> y){
cout << a[i - 1] * y << endl;
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include<iostream>
using namespace std;
int main(){
int t,n,tmp[]={6000,4000,3000,2000};
for(int i = 0 ; i < 4 ; i++){
cin >> t >> n;
cout << tmp[t-1] * n << endl;
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include <bits/stdc++.h>
#define int long long
#define double long double
using namespace std;
signed main() {
int prices[] = { 6000, 4000, 3000, 2000 };
for (int i = 0; i < 4; i++) {
int t, n;
cin >> t >> n;
cout << prices[t-1]*n << endl;
}
}
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include <iostream>
using namespace std;
int main() {
int m,n;
int price[4]={6000,4000,3000,2000};
for(int i=0;i<4;i++){
cin >> m >> n;
cout << price[m-1]*n << endl;
}
return 0;
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | java | import java.util.Scanner;
class Main{
int t;
int n;
int cnt=0;
public void solve(){
Scanner sc=new Scanner(System.in);
while(cnt<4){
t=sc.nextInt();
n=sc.nextInt();
if(t==1){
System.out.println(6000*n);
cnt++;
}else if(t==2){
System.out.println(4000*n);
cnt++;
}else if(t==3){
System.out.println(3000*n);
cnt++;
}else{
System.out.println(2000*n);
cnt++;
}
}
}
public static void main(String[] args){
Main obj =new Main();
obj.solve();
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | python3 | a=[0,6000,4000,3000,2000]
for x in range(4):
t,n=list(map(int,input().split()))
print(a[t]*n)
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | python3 |
a,m=map(int, input().split())
b,n=map(int, input().split())
c,l=map(int, input().split())
d,o=map(int, input().split())
def cal(e,p):
if e==1:
x=p*6000
return x
elif e==2:
x=p*4000
return x
elif e==3:
x=p*3000
return x
else:
x=p*2000
return x
x1=cal(a,m)
x2=cal(b,n)
x3=cal(c,l)
x4=cal(d,o)
print(x1)
print(x2)
print(x3)
print(x4)
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include <cstdio>
#include <cstdlib>
using namespace std;
int main()
{
int in[2],varue[4] = {6000,4000,3000,2000};
for(int i = 0; i < 4; i++){
scanf("%d %d",&in[0],&in[1]);
printf("%d\n",in[1] * varue[in[0]-1]);
}
return 0;
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include<iostream>
using namespace std;
int main(){
int yen[]={6000,4000,3000,2000},n,t;
for(int i=0;i<4;i++){
int sum=0;
cin>>t>>n;
sum=yen[t-1]*n;
cout<<sum<<endl;
}
return 0;
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | python3 | for i in range(4):
a,b=map(int,input().split())
if a==1:
a=b*6000
if a==2:
a=b*4000
if a==3:
a=b*3000
if a==4:
a=b*2000
print(a)
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | python3 | for x in range(4):
t,n=map(int,input().split())
if t==1:
print(6000*n)
if t==2:
print(4000*n)
if t==3:
print(3000*n)
if t==4:
print(2000*n)
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include <bits/stdc++.h>
using namespace std;
int main(){
int a[4];
a[0] = 6000;
a[1] = 4000;
a[2] = 3000;
a[3] = 2000;
for(int i = 0; i < 4; i++){
int m,n;
cin >> m>>n;
cout << a[m-1] *n <<endl;
}
return 0;
}
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include <cstdio>
int v[]={6000,4000,3000,2000};
int main() {
for(int i=0;i<4;i++) {
int t,n;
scanf("%d %d",&t,&n);
printf("%d\n",v[t-1]*n);
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include<bits/stdc++.h>
using namespace std;
int main(){
int t[4]={6000,4000,3000,2000};
int a,b;
int c[4];
for(int i=0;i<4;i++){
cin>> a>> b;
c[i]=b*t[a-1];
}
for(int i=0;i<4;i++){
cout<< c[i]<< endl;
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | java | import java.util.*;
public class Main{
public static void main(String args[]){
Scanner sc = new Scanner(System.in);
while(sc.hasNext()){
long a = sc.nextLong();
long b = sc.nextLong();
long cost = 0;
if(a == 1){ cost = 6000 * b;}
if(a == 2){ cost = 4000 * b;}
if(a == 3){ cost = 3000 * b;}
if(a == 4){ cost = 2000 * b;}
System.out.println(cost);
}
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | python3 | a=[0,6000,4000,3000,2000]
for i in range(4):
t,n=map(int,input().split())
print(n*a[t])
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | python3 | t1,n1=map(int,input().split())
t2,n2=map(int,input().split())
t3,n3=map(int,input().split())
t4,n4=map(int,input().split())
if t1==1:
t1=6000
elif t1==2:
t1=4000
elif t1==3:
t1=3000
else:
t1=2000
if t2==1:
t2=6000
elif t2==2:
t2=4000
elif t2==3:
t2=3000
else:
t2=2000
if t3==1:
t3=6000
elif t3==2:
t3=4000
elif t3==3:
t3=3000
else:
t3=2000
if t4==1:
t4=6000
elif t4==2:
t4=4000
elif t4==3:
t4=3000
else:
t4=2000
print(t1*n1)
print(t2*n2)
print(t3*n3)
print(t4*n4)
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include <iostream>
using namespace std;
int main(void) {
int kingaku[] = {6000, 4000, 3000, 2000} ;
for (int i = 0; i < 4; i++) {
int t,n;
cin >> t >> n;
cout << kingaku[t-1] * n << endl;
}
return 0;
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | python3 | v = [0,6000,4000,3000,2000]
for i in range(4):
t,n = map(int,input().split())
print(n*v[t])
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | java | import java.util.Scanner;
public class Main {
Scanner sc = new Scanner(System.in);
int cnt;
int seki;
int kingaku;
int maisuu;
int[] uriage = new int [4];
public void syurui(){
for (cnt=0;cnt<=3;cnt++){
seki = sc.nextInt();
maisuu = sc.nextInt();
switch(seki) {
case 1: kingaku=6000; break;
case 2: kingaku=4000; break;
case 3: kingaku=3000; break;
case 4: kingaku=2000; break;
}
uriage[cnt] = kingaku*maisuu;
}
}
public void keisan(){
for (cnt=0;cnt<=3;cnt++){
System.out.println(uriage[cnt]);
}
}
public static void main(String[] args) {
// TODO 自動生成されたメソッド・スタブ
Main yo = new Main();
yo.syurui();
yo.keisan();
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include<iostream>
using namespace std;
int main()
{
for (int a = 0; a < 4; a++)
{
int c, d;
cin >> c >> d;
switch (c)
{
case 1:cout<< d * 6000<<endl; break;
case 2:cout << d * 4000 << endl; break;
case 3:cout << d * 3000 << endl; break;
default:cout << d * 2000 << endl;
}
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include<bits/stdc++.h>
using namespace std;
typedef long long int64;
int main(){
int ticket[] = { 6000, 4000, 3000, 2000};
for(int i = 0; i < 4; i++){
int t, n;
cin >> t >> n;
cout << ticket[t - 1] * n << endl;
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | java | import java.util.Scanner;
public class Main{
public static void main(String[]args){
Scanner sc =new Scanner(System.in);
int Su[] ={0,6000,4000,3000,2000};
int Ke[] ={0,0,0,0};
for(int i = 0; i < 4; i++){
int a = sc.nextInt();
int b = sc.nextInt();
Ke[i] = Su[a] * b;
}
for(int n = 0; n < 4; n++){
System.out.println(Ke[n]);
}
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include <iostream>
using namespace std;
int main(){
int com[] = {0, 6000, 4000, 3000, 2000};
int t, n;
for (int i = 0; i < 4; i++){
cin >> t >> n;
cout << com[t] * n << endl;
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | java | //2718 佐々木 稜平 問2
import java.util.Scanner;
public class Main{
public void solve(){
Scanner sc = new Scanner(System.in);
for(int a =0;a<4;a++){
int t = sc.nextInt();
int n = sc.nextInt();
switch (t){
case 1:
System.out.println(n*6000);
break;
case 2:
System.out.println(n*4000);
break;
case 3:
System.out.println(n*3000);
break;
case 4:
System.out.println(n*2000);
break;
}
}
}
public static void main(String[] args){
Main obj = new Main();
obj.solve();
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | python3 | while True:
try:
t,n=map(int,input().split())
if t==1:
k=6000
elif t==2:
k=4000
elif t==3:
k=3000
else:
k=2000
print(k*n)
except:
break
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include <iostream>
using namespace std;
int cost[5]={0,6000,4000,3000,2000};
int main() {
int t,n;
for(int i=0;i<4;i++)
{
cin >> t >> n;
cout << cost[t]*n << endl;
}
return 0;
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include <bits/stdc++.h>
using namespace std;
#define FOR(i, a, b) for (int i = (a); i < (b); i++)
#define REP(i, n) for (int i = 0; i < (n); i++)
int seat[] = {0, 6000, 4000, 3000, 2000};
int main()
{
int t, n;
FOR(i, 1, 5){
cin >> t >> n;
cout << seat[t] * n << endl;
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | java | import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner stdIn = new Scanner(System.in);
int a[]=new int[8];
int b[]=new int[4];
for(int i=0;i<4;i++){
int se =stdIn.nextInt();
int mai=stdIn.nextInt();
switch(se){
case 1:
a[i]=mai*6000;
break;
case 2:
a[i]=mai*4000;
break;
case 3:
a[i]=mai*3000;
break;
case 4:
a[i]=mai*2000;
break;
}
}for(int i=0;i<4;i++){
System.out.println(a[i]);
}
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | java | //2734 吉原直樹 問0277
import java.util.Scanner;
public class Main{
int kind;
int su;
int kei;
int []seki = {6000,4000,3000,2000};
public void solve(){
Scanner sc = new Scanner(System.in);
for(int k=0;k<4;k++){
kind=sc.nextInt();
switch(kind){
case 1:
kind=6000;
break;
case 2:
kind=4000;
break;
case 3:
kind=3000;
break;
case 4:
kind=2000;
break;
}
su=sc.nextInt();
kei=kind*su;
System.out.println(kei);
}
}
public static void main(String[] args){
Main obj = new Main();
obj.solve();
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | java | import java.util.Scanner;
public class Main{
int seki[]={0,6000,4000,3000,2000};
int b;
int a;
int kin=0;
public void solve(){
Scanner sc=new Scanner(System.in);
for(int i=1;i<5;i++){
a = sc.nextInt();
b = sc.nextInt();
kin =seki[a]*b;
System.out.println(kin);
}
}
public static void main(String[] args){
Main obj=new Main();
obj.solve();
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include <iostream>
using namespace std;
int main(){
for(int i=0;i<4;i++){
int t,n;cin>>t>>n;
if(t%4==1){
cout<<n*6000<<endl;
}else if(t%4==2){
cout<<n*4000<<endl;
}else if(t%4==3){
cout<<n*3000<<endl;
}else{
cout<<n*2000<<endl;
}
}
}
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | python3 | i=0
m=0
for i in range(4):
a,b=map(int,input().split())
if a==1:
print(6000*b)
elif a==2:
print(4000*b)
elif a==3:
print(3000*b)
else:
print(2000*b)
i+=1
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include<iostream>
using namespace std;
int main(void){
int t, n;
for(int i = 0; i < 4; i++){
cin >> t >> n;
if(t == 1) cout << n*6000 << endl;
else if(t == 2) cout << n*4000 << endl;
else if(t == 3) cout << n* 3000 << endl;
else cout << n*2000 << endl;
}
return 0;
}
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include <iostream>
using namespace std;
int main(){
int A[5]={0,6000,4000,3000,2000};
for(int i=0;i<4;++i){
int t,n,sum;
cin>>t>>n;
sum=A[t]*n;
cout<<sum<<endl;
}
return 0;
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | java |
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.StringTokenizer;
public class Main {
public static void main(String[] args) {
BufferedReader bfr=new BufferedReader(new InputStreamReader(System.in));
StringTokenizer stk;
String str="";
int S_ndn,A_ndn,B_ndn,C_ndn;
int sum=0;
S_ndn=6000; A_ndn=4000; B_ndn=3000; C_ndn=2000;
int tmp1,tmp2;
try {
for(int i=0; i<4; i++) {
str=bfr.readLine();
stk=new StringTokenizer(str," ");
tmp1=Integer.parseInt(stk.nextToken());
tmp2=Integer.parseInt(stk.nextToken());
if(tmp1==1) {
sum+=tmp2*S_ndn;
}
else if(tmp1==2) {
sum+=tmp2*A_ndn;
}
else if(tmp1==3) {
sum+=tmp2*B_ndn;
}
else if(tmp1==4) {
sum+=tmp2*C_ndn;
}
System.out.println(sum);
sum=0;
}
}catch(IOException e) {
}
}
}
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include <iostream>
using namespace std;
int main() {
int t, n;
int price[4] = {6000, 4000, 3000, 2000};
int i;
for (i = 0; i < 4; i++) {
cin >> t >> n;
cout << price[t - 1] * n << endl;;
}
return 0;
}
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | java | import java.util.Scanner;
public class Main{
public void solve(){
Scanner sc = new Scanner(System.in);
int syu,mai,b,uri;
for(int t=0; t<4; t++){
syu = sc.nextInt();
if(syu==1){
b=6000;
}else if(syu==2){
b=4000;
}else if(syu==3){
b=3000;
}else{
b=2000;
}
mai = sc.nextInt();
uri = b*mai;
System.out.println(uri);
}
}
public static void main(String[] args){
Main obj = new Main();
obj.solve();
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | python3 | for i in range(4):
a,b = map(int,input().split())
if a == 1:
print(6000*b)
elif a == 2:
print(4000*b)
elif a == 3:
print(3000*b)
elif a == 4:
print(2000*b)
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include<bits/stdc++.h>
using namespace std;
int main(void)
{
int i,a,b,t[4]={6000,4000,3000,2000};
for(i=0;i<4;i++) {
cin>>a>>b;
cout<<t[a-1]*b<<endl;
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include <iostream>
using namespace std;
const int money[] = {0, 6000, 4000, 3000, 2000};
int main()
{
int t, n;
for (int i = 0; i < 4; i++) {
cin >> t >> n;
cout << money[t] * n << endl;
}
return 0;
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include <iostream>
using namespace std;
int main(){
int pr[4]={6000,4000,3000,2000};
int a,b;
for(int i=0;i<4;i++){
cin >> a >> b;
cout << pr[a-1] * b << endl;
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | java | import java.util.*;
public class Main {
public static void main(String args[]){
Scanner in = new Scanner(System.in);
int[]n = new int [5];
for(int i = 1;i < 5;i++){
int t = in.nextInt();
n[t] = in.nextInt();
if(t == 1){
System.out.println(6000*n[1]);
}else if(t == 2){
System.out.println(4000*n[2]);
}else if(t == 3){
System.out.println(3000*n[3]);
}else{
System.out.println(2000*n[4]);
}
}
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include<stdio.h>
int main(void)
{
int t,n,a[4],i,j;
for(i=0;i<4;i++){
scanf("%d %d",&t,&n);
if(t==1){
a[i]=n*6000;
}
if(t==2){
a[i]=n*4000;
}
if(t==3){
a[i]=n*3000;
}
if(t==4){
a[i]=n*2000;
}
}
for(j=0;j<4;j++){
printf("%d\n",a[j]);
}
return 0;
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include <cstdio>
int p[]={6000,4000,3000,2000};
int main() {
int ans=0;
for(int i=0;i<4;i++) {
int t,n;
scanf("%d %d",&t,&n);
printf("%d\n",p[t-1]*n);
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include<stdio.h>
int main(void)
{
int a[5]={1,2,3,4};
int t[10],n[10001],c[90000],i;
a[1]=6000;
a[2]=4000;
a[3]=3000;
a[4]=2000;
for(i=0;i<4;i++){
scanf("%d %d",&t[i],&n[i]);
c[i]=a[t[i]]*n[i];
}
for(i=0;i<4;i++){
printf("%d\n",c[i]);
}
return 0;
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include<bits/stdc++.h>
using namespace std;
int main()
{
int a[4]={6000,4000,3000,2000},b,c;
for(int i=0;i<4;i++){
cin>>b>>c;
cout<<c*a[b-1]<<endl;
}
return 0;
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include<iostream>
using namespace std;
int main()
{
int a[] = { 6000, 4000, 3000, 2000 };
for (int i = 0; i < 4; i++){
int x, y;
cin >> x >> y;
cout << a[x - 1] * y << endl;
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | java | import java.util.Scanner;
public class Main {
/**
* @param args
*/
public static void main(String[] args) {
int[] nedan = {6000,4000,3000,2000};
int i, s, mai;
Scanner sc = new Scanner(System.in);
for ( i = 0; i <= 3; i++) {
s = sc.nextInt();
mai = sc.nextInt();
System.out.println(nedan[s-1] * mai);
}
// TODO 自動生成されたメソッド・スタブ
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include<iostream>
using namespace std;
int tic[] = {6000,4000,3000,2000};
int main(){
for(int i = 0; i < 4; i++){
int t,n;
cin >> t >> n;
cout << tic[t-1]*n << endl;
}
return 0;
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | java | import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.StringTokenizer;
public class Main {
static int[] prices = { 0, 6000, 4000, 3000, 2000 };
public static void main(String[] args) throws IOException {
BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
String line = "";
while ((line = br.readLine()) != null && !line.isEmpty()) {
StringTokenizer st = new StringTokenizer(line);
int t = Integer.parseInt(st.nextToken());
int n = Integer.parseInt(st.nextToken());
System.out.println(prices[t] * n);
}
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include<cstdio>
using namespace std;
int main(){
int data[] = {0,6000,4000,3000,2000};
for(int i=0;i<4;i++){
int t,n;
scanf("%d %d",&t,&n);
printf("%d\n",data[t]*n);
}
return 0;
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | python3 | t1,n1=map(int,input().split())
t2,n2=map(int,input().split())
t3,n3=map(int,input().split())
t4,n4=map(int,input().split())
def keisan(t,n):
if t==1:
return(n*6000)
elif t==2:
return(n*4000)
elif t==3:
return(n*3000)
else:
return(n*2000)
print(keisan(t1,n1))
print(keisan(t2,n2))
print(keisan(t3,n3))
print(keisan(t4,n4))
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include<iostream>
using namespace std;
int main()
{
int nedan[] = {6000,4000,3000,2000};
for(int i=0 ; i<4 ; ++i){
int t,n;
cin >> t >> n;
cout << nedan[t-1]*n << endl;
}
return 0;
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include<iostream>
using namespace std;
int main(){
int r[5]={0,6000,4000,3000,2000};
for(int i=0;i<4;i++){
int t,n;
cin>>t>>n;
cout<<r[t]*n<<endl;
}
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include<iostream>
using namespace std;
int main(){
int t,n;
int tt[4]={6000,4000,3000,2000};
for(int i=0;i<4;i++){
cin >> t >> n;
cout << tt[t-1] * n << endl;
}
return 0;
}
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | python3 | p=[0,6000,4000,3000,2000]
for i in range(4):
t,n=map(int,input().split())
print(p[t]*n)
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | java | import java.util.Scanner;
class Main {
public static void main(String[] args) {
Scanner scan = new Scanner(System.in);
int t;
int n;
int i;
for(i = 0;i<4;i++){
t = scan.nextInt();
n = scan.nextInt();
if(t == 1){
System.out.println(6000*n);
}else if (t == 2){
System.out.println(4000*n);
}else if (t == 3){
System.out.println(3000*n);
}else if (t == 4){
System.out.println(2000*n);
}
}
}
}
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include<iostream>
#include<algorithm>
using namespace std;
int t, n;
int cost[] = {0, 6000, 4000, 3000, 2000};
int main(){
for(int i = 0;i < 4;i++){
cin >> t >> n;
cout << cost[t] * n << endl;
}
return 0;
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include<stdio.h>
int main(){
int x,y;
//while(scanf("%d %d",&x,&y)!=EOF){
for(int i=0;i<4;i++){
scanf("%d %d",&x,&y);
int t=0;
switch(x){
case 1:
t=6000;break;
case 2:
t=4000;break;
case 3:
t=3000;break;
case 4:
t=2000;break;
}
printf("%d\n",t*y);
}
return 0;
} |
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | python3 | V = [0, 6000, 4000, 3000, 2000]
for i in range(4):
t, n = map(int,input().split())
print(n*V[t])
|
p00272 Ticket Sales | Today is the ticket release date for Aizu Entertainment's recommended idol group "Akabeko & Koboushi". There are four types of tickets:
S seat 6000 yen
A seat 4000 yen
B seat 3000 yen
C seat 2000 yen
You, the sales manager, are excitedly waiting for the launch. Finally on sale. It's selling very well!
Shortly after the launch, I received a table summarizing the orders up to that point. Each row of the table shows the type and number of tickets sold so far. However, the ticket types do not always appear in the order of S, A, B, C. Create a program to find the sales amount for each row in this table.
input
Input data is given in the following format.
t1 n1
t2 n2
t3 n3
t4 n4
The input consists of 4 lines. Line i is given the integer ti (1 ≤ ti ≤ 4) for the ticket type and the integer ni (0 ≤ ni ≤ 10000) for the number of tickets. The integers 1, 2, 3, and 4 representing the ticket types represent S seats, A seats, B seats, and C seats, respectively. Numbers from 1 to 4 always appear once as values for t1, t2, t3, and t4, but they are not always given in the order of 1, 2, 3, 4.
output
Output the sales amount for each line.
Example
Input
3 10
1 4
4 1
2 5
Output
30000
24000
2000
20000 | {
"input": [
"3 10\n1 4\n4 1\n2 5"
],
"output": [
"30000\n24000\n2000\n20000"
]
} | {
"input": [],
"output": []
} | CORRECT | cpp | #include <iostream>
using namespace std;
int main() {
int a,b;
for (int i=0;i<4;++i){
cin >>a>>b;
if(a==1)b=b*6000;
if(a==2)b=b*4000;
if(a==3)b=b*3000;
if(a==4)b=b*2000;
cout<<b<<endl;
}
return 0;
} |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.