**Physical Address**

304 North Cardinal St.

Dorchester Center, MA 02124

Problem – Single Operation Part 2 CodeChef Solution Chef has the binary representation S of a number X with him. He can modify the number by applying the following operation exactly once: Chef wants to minimize the value of X after performing the operation. Help Chef in determining the…

Problem – Binary Substituition CodeChef Solution Chef has a binary string S. He can replace any occurrence of – While doing these operations, Chef noticed that he can end up with different strings depending upon the order of application of the…

Problem – Odd Sum Pair CodeChef Solution Chef has 3 numbers A,B and C. Chef wonders if it is possible to choose exactly two numbers out of the three numbers such that their sum is odd. Input Format Output Format For each test case, output YES if you can choose…

Problem – Good Pairs CodeChef Solution You are given N integers: A1, A2, …, AN. You need to count the number of pairs of indices (i, j) such that 1 ≤ i < j ≤ N and Ai | Aj ≤ max(Ai, Aj). Note: Ai | Aj refers to bitwise OR. Input Output For each test case, output a single line containing…

Problem – A – Save Water Save Life CodeChef Solution To address the situation of Water Scarcity in Chefland, Chef has started an awareness campaign to motivate people to use greywater for toilets, washing cars, gardening, and many other chores…

Problem – Hidden Numbers CodeChef Solution Salmon has some hidden numbers that he wants you to find! Given an integer N, find and output any two integers A and B such that: ###Input: The first line of input consists of a single integer T (1≤T≤10^5)…

Problem – The Rating Dilemma CodeChef Solution Chef really likes to compete on Codechef, and he has gained an impressive rating of X, where X>0. There is also a parallel universe, where ratings on Codechef are negative instead. The only thing that…

Problem – HOW MANY DIGITS DO I HAVE CodeChef Solution Write a program to obtain a number (N) from the user and display whether the number is a one digit number, 2 digit number, 3 digit number or more than 3 digit…

Problem – Peaceful Party CodeChef Solution The mayor of your city has decided to throw a party to gather the favour of his people in different regions of the city. There are 3 distinct regions in the city namely A, B, C comprising of PA, PB and PC number of…

Problem – Passing Marks CodeChef Solution Recently, Chef’s College Examination has concluded. He was enrolled in 3 courses and he scored A,B,C in them, respectively. To pass the semester, he must score at least Amin,Bmin,Cmin marks in the respective subjects along with a cumulative score of…