Logo
(追記) (追記ここまで)

24603번 - Scaling Recipe 다국어

시간 제한메모리 제한제출정답맞힌 사람정답 비율
1 초 (추가 시간 없음) 1024 MB42233030877.387%

문제

You've got a recipe which specifies a number of ingredients, the amount of each ingredient you will need, and the number of portions it produces. But, the number of portions you need is not the same as the number of portions specified in the recipe! How can you scale it?

입력

The first line of input contains three integers $n$ (1ドル \le n \le 40$), $x$ and $y$ (1ドル \le x,y \le 40{,}000$), where $n$ is the number of ingredients in the recipe, $x$ is the number of portions that the recipe produces, and $y$ is the number of portions you need.

Each of the next $n$ lines contains a single integer $a$ (1ドル \le a \le 40{,}000$). These are the amounts of each ingredient needed for the recipe.

The inputs will be chosen so that the amount of each ingredient needed for $y$ portions will be an integer.

출력

Output $n$ lines. On each line output a single integer, which is the amount of that ingredient needed to produce $y$ portions of the recipe. Output these values in the order of the input.

제한

예제 입력 1

2 4 10
8
12

예제 출력 1

20
30

예제 입력 2

3 37627 38021
34571
38009
34189

예제 출력 2

34933
38407
34547

힌트

출처

ICPC > Regionals > North America > Pacific Northwest Regional > 2021 ICPC Pacific Northwest Region > Division 2 N번

(追記) (追記ここまで)

출처

대학교 대회

  • 사업자 등록 번호: 541-88-00682
  • 대표자명: 최백준
  • 주소: 서울시 서초구 서초대로74길 29 서초파라곤 412호
  • 전화번호: 02-521-0487 (이메일로 연락 주세요)
  • 이메일: contacts@startlink.io
  • 통신판매신고번호: 제 2017-서울서초-2193 호

AltStyle によって変換されたページ (->オリジナル) /