HomeVolumesContestsSectionsForumsUsersPrintHelpAbout

Volumes > Functions > problem:


260. 50493 - n-digit kth Prime Number

Guest
• Review clarifications (1)

Volume problems

• 095. 50453 - The Cubic Difference
• 125. 50578 - Mersenne prime
• 132. 50474 - Sum of Two Primes
• 165. 50577 - Perfect Numbers and ...
• 190. 50533 - Contacts List
• 200. 50454 - What day is it?
• 210. 50369 - Base Conversion
• 250. 50385 - The 3n + 1 problem
• 260. 50493 - n-digit kth Prime ...
• 50307 - Palindromes
• 50305 - John's Tasks
• 002. 50428 - Three Times
• 010. 50582 - Number of digits
• 035. 50467 - Random Numbers
• 062. 50390 - Total Salary Paid
• 100. 50397 - The Number of Points ...
• 135. 50572 - Palindromic Numbers

Feedback

If you notice incorrect translations in Contester, please let author know.

Time limit 2000/4000/4000/4000 ms. Memory limit 65000/65000/65000/65000 Kb.
Question by Ibrahim Mesecan.

n-digit kth Prime Number

Question: When calculating the area of an irregular polygon, all the vertices are written down in order ending with the starting vertex. Then the product of first y is with the second x is subtracted from the product of first x is with the second y.

Write a program that shows kth n-digit prime number. For example, the following are the first 10, 3-digit prime numbers:
   101 103 107 109 113 127 131 137 139 149
And, 5th 3-digit prime number is 113.

Input specification
You will be given two integers number (n and k) where is 1 ≤ n ≤ 12 and 1 ≤ k ≤ 100.

Output specification
Show one number: kth n-digit prime number.

 Sample Input I   
 4 2
 Sample Input II   
 10 10
 Sample Output I   
 1013
 Sample Output II   
 1000000181


Для отправки решений необходимо выполнить вход.

www.contester.ru