PROBLEMS

Test Page

Question Solution – Python Question Given an array of integers nums and an integer target, return indices of the two numbers such that they add up to target. You may assume that each input would have exactly one solution, and you may not use the same element twice. You can return the answer in any order. Example 1: Input: nums = [2,7,11,15], target = …

Test Page Read More »

Hidden Pattern String

Given two strings – a text A and a pattern B, having lower-case alphabetic characters. You have to determine the number of occurrences of pattern B in text A as its substring. i.e. the number of times B occurs as a substring in A. Problem Constraints 1 <= |B| <= |A| <= 105 Input Format First argument is a …

Hidden Pattern String Read More »

Calculate Currency Change

Calculate Currency Change Write Code Problem Description Your friend Rahul plans to visit exotic countries all around the world. Sadly, Rahul’s math skills aren’t good. He’s pretty worried about being scammed by currency exchanges during his trip – and he wants you to make a currency calculator for him. Here are his specifications for the …

Calculate Currency Change Read More »

Number of bills

Number of bills Write Code Problem Description Your friend Rahul plans to visit exotic countries all around the world. Sadly, Rahul’s math skills aren’t good.He’s pretty worried about being scammed by currency exchanges during his trip – and he wants you to make a currency calculator for him. Here are his specifications for the app: …

Number of bills Read More »

Concatenate Two Numbers

Concatenate Two Numbers Write Code Problem Description Given two numbers A and B. Concatenate the two numbers and print it. Problem Constraints 1 <= A, B <= 104 Input Format There are two input lines The first line has a single integer A. The second line has a single integer B. Output Format Print in a single line the concatenated …

Concatenate Two Numbers Read More »

Fizz Buzz Implementation

Fizz Buzz Implementation​ Write Code Write a program that prints the numbers from 1 to 100 and for multiples of ‘3’ print “Fizz” instead of the number and for the multiples of ‘5’ print “Buzz”.  1, 2, Fizz, 4, Buzz, Fizz, 7, 8, Fizz, Buzz, 11, Fizz, 13, 14, Fizz Buzz, 16, 17, Fizz, 19, …

Fizz Buzz Implementation Read More »