시간 제한 | 메모리 제한 | 제출 | 정답 | 맞힌 사람 | 정답 비율 |
---|---|---|---|---|---|
3 초 (추가 시간 없음) | 1024 MB | 47 | 23 | 19 | 50.000% |
Eric developed a new algorithm to mine a cryptocurrency called Eatcoin. Since Eric’s algorithm is an evolutionary algorithm, its performance keeps improving. On the d-th day of the execution of Eric’s algorithm, it consumes p Eatcoins and then produces q × d5 Eatcoins where p and q are positive constants.
Eric wants to become a “duotrigintillionaire”. A duotrigintillionaire is a person who has at least 1099 Eatcoins. Eric plans to exploit his algorithm to achieve his goal. Eric’s algorithm can soon produce a massive amount of Eatcoins if he has enough Eatcoins. However, his algorithm cannot continue if he does not have p Eatcoins when needed.
Eric gives the values of p and q to you. Please write a program to help Eric to compute two numbers x and y defined as follows.
Two positive integers p and q are given in one line and separated by a space.
Output two lines. Print x on the first line and y on the second line.
50 1
117 42627697484524538
10 10
10 29041912218408574
ICPC > Regionals > Asia Pacific > Taiwan > Taiwan Online Programming Contest > TOPC 2021 E번