# NumberTheory Problems

 N-th PrimeIn this problem, you will have to print the nnn-th prime number. The first few prime numbers are giv... Very Easy 766/1k/4k Magic NumberJack loves to play with numbers. One day, while he was playing with numbers he found something inter... Very Easy 173/262/952 For Loop FTWYou are given an integer N which can be represnted as the product of two positive integers. N=a1∗a2 ... Very Easy 461/465/548 Relatively PrimeGiven a positive integer N, determine how many of the integers between 1 and N are co-prime with N. ... Very Easy 163/165/204 Ishtiaque and the RabbitMr Ishtiaque is in trouble. A few months ago, he bought 2 rabbits. He wanted to have two pet rabbits... I Did Not Do the AssignmentProfessor Petr is very angry over some of his students now-a-days for not doing assignment. He wants... Love Letters!Lately Fahim is getting a lot of love letters. A LOT of love letters. Since he is confused about whi... Equation Equals HazardsYou are given the equation, GCD(A,M) = 1. You have to determine whether there exists at least one in... Very Easy 56/69/163 Is It PerfectBob has an initial array D of length n . Alice is a good friend of Bob. So Bob challenges Alice to f... Moderate 19/24/58 Kitorp and His LoveKitorp loves his wife Asiar(who is a problem solver as well) but he loves math more. To get his atte... Challenging LoverGreetings to all of you. You must have heard about our star programmer Rafat bhai. One day he went o... Very Easy 169/221/723 A Lack of Common DivisorsGiven a positive integer NNN, determine how many of the integers between 1 and NNN are co-prime with... A GRE Themed Contest ProblemSadman and Najkin were solving a GRE math problem, Rejbah another friend of theirs listened to that ... Life of PhiThe Great Khami is learning Number Theory. He is very excited to know that Euler's Totient Function ... Moderate 265/502/2k Zacob the BatsmanIt's known that Zacob is a reliable batsman of LU CSE Cricket Team. Also as long as he is on the cre... Birthday SurpriseAdnan bhai, Priyom dada and Shuvo bhai are the members of MU_Kheloars. They recently got graduated a... Moderate 16/23/104 Prime RangePrime Numbers are such numbers which are only divided by 1 and the number itself. 2, 3, 5, 7, 11, 13... Fast Co-PrimeTwo numbers A and B are called co-prime if the only common positive factor of the two numbers is 1. ... Correct the SieveSieve of Eratosthenes is a fast algorithm for finding prime numbers in larger ranges. According to W... Exponential GrowthYou will be given two integers XXX and NNN, you have to calculate XNX^NXN modulo 1000000007. Dividing the GiftsToday is a very good day in CSEmpur because Tuktuki has bought N gifts! Tuktuki wants to give these ... Easy Factorial?It is time to show your performance on number theory. Why so late? Come to the point. You are given... K-Th RootYou will be given Q queries. In each query, you will be given two positive integers A and B. You hav... Is Bita Happy?Bita has learned bitwise-operations recently. She is doing some experiments with these operations no... Moderate 33/64/198 Find the primes?For a positive integer n, let’s define a function f: f(n) = sum of positive integers less than n whi... Moderate 11/22/229