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

7765번 - Supersquare 스페셜 저지다국어

시간 제한메모리 제한제출정답맞힌 사람정답 비율
1 초 128 MB4611838.095%

문제

Let number A be a precise square if there exists natural number B such that B*B = A.

2n-digit number without leading zeroes is called a supersquare if it is a precise square and both n-digit numbers which are formed from its n first digits and its n last digits are precise squares. The second n-digit number dndn-1…d1 formed from n last digits may have leading zeroes but must not be equal zero.

You need to write a program which constructs a 2n-digit number which is supersquare.

입력

The input contains several test cases. The first line contains the number of test cases T (1 ≤ T ≤ 10). Each of the next T lines describes one test case and contains an integer number n (1 ≤ n ≤ 500).

출력

The output consists of T lines, one line per each test case. Each line contains 2n-digit supersquare number. If several solutions are possible only one of them should be given. When it is impossible to construct 2n-digit supersquare, the line must contain NO SUPERSQUARE POSSIBLE phrase.

제한

예제 입력 1

2
1
2

예제 출력 1

49
1681

힌트

출처

ICPC > Regionals > Northern Eurasia > Northwestern Russia Regional Contest > NEERC Western Subregional 2005 F번

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

출처

대학교 대회

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

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