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

24828번 - Random Digital Exponentiation 다국어

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

문제

In a random digital exponentiation (RDE) cipher, each digit of a number $a$ is raised to a certain power which is determined by a randomly chosen encryption key. The encrypted number is the number that results when each digit is replaced with its power at the corresponding place value.

For instance, for $a = 243$ and an encryption key of 7 4 3, the encrypted value $b$ would be $b = 2^7 \times 10^2 + 4^4 \times 10 + 3^3 = 15,387円$.

Given a plaintext value $a$ and an encrypted value $b,ドル find the encryption key that was used!

입력

The input will contain a single test case containing two numbers $a$ and $b$ (0ドル \le a \le b \le 2,147円,483円,647円$).

출력

Print the encryption key, which is the list of exponents to which each digit in $a$ was raised, separated by spaces, starting from the leftmost digit's exponent. Each exponent should be a natural number. You are guaranteed that the encryption key exists and is unique.

제한

예제 입력 1

243 15387

예제 출력 1

7 4 3

힌트

출처

School > Virginia Tech High School Programming Contest > 2019 Virginia Tech High School Programming Contest K번

  • 문제를 만든 사람: Brook Tamir
(追記) (追記ここまで)

출처

대학교 대회

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

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