Gblog Must Do Coding Questions for Product Based Companies
As the placement season is back, GeeksforGeeks is here to help you crack the interview. We have selected some most commonly asked and MUST DO… Read More
Given n stairs and we have 2 colour yellow and green the task is that we have to paint given stairs by given colour with… Read More
Given a maximum limit of x – coordinate and y – coordinate, we want to calculate a set of coordinates such that the distance between… Read More
Given a single integer n [1, 1000000000], generate a Pythagoras triplet which includes n as one of its sides if possible.Examples :   Input : 22 Output… Read More
Given a huge integer value n, find the largest integer value x such that x <= n and all the digits of x are prime.Examples: … Read More
Given a number s (1 <= s <= 1000000000). If this number is the sum of first n natural number then print, otherwise print -1. Examples: … Read More
This was a pool campus conducted by amazon for internship. Online Round: There were 20 mcq(+1 for each) and 2 coding questions(+30 for each). MCQ had… Read More
Define a function int max(int a[], int n) which returns the largest integer from an integer array consisting of n elements (without using conditionals /… Read More
You are given an integer n, find the smallest positive integer root of equation x, or else print -1 if no roots are found.Equation: x^2… Read More
Variable length argument is a feature that allows a function to receive any number of arguments. There are situations where we want a function to… Read More
Given two numbers base and exp, we need to compute baseexp under Modulo 10^9+7 Examples: Input : base = 2, exp = 2 Output :… Read More
Given an positive large integer n. Count the number of positive divisors of n2 which are not divisible by any divisor of n(1 <= n… Read More
Travelling Salesman Problem (TSP) : Given a set of cities and distances between every pair of cities, the problem is to find the shortest possible… Read More
Newgen  Software came to a college for pool drive Software Engineer profile. (Eligible branches-CSE and IT). Round 1:(Online Round) 32 students were shortlisted from our… Read More
Design a program to take a word as an input, and then encode it into Pig Latin. A Pig Latin is an encrypted word in… Read More
Given a non-negative number N in the form of string. The task is to apply at most one swap operation on the number N so… Read More