• Skip to primary navigation
  • Skip to content
  • Skip to primary sidebar
  • Skip to secondary sidebar

GoHired

Interview Questions asked in Google, Microsoft, Amazon

Join WeekEnd Online Batch from 4-April-2020 on How to Crack Coding Interview in Just 10 Weeks : Fees just 20,000 INR

  • Home
  • Best Java Books
  • Algorithm
  • Internship
  • Certificates
  • About Us
  • Contact Us
  • Privacy Policy
  • Array
  • Stack
  • Queue
  • LinkedList
  • DP
  • Strings
  • Tree
  • Mathametical
  • Puzzles
  • Graph

Dhaval Dave

Find an index i such that Arr [i] = i in array of n distinct integers sorted in ascending order.

August 12, 2014 by Dhaval Dave

Given an array of n distinct integers sorted in ascending order, write a function that returns a Fixed Point in the array such that Arr[i] = i .
If there is any Fixed Point present
… Read More

Filed Under: Amazon Interview Question, Flipkart Interview Questions, Hacker Earth Questions, Interview Questions, problem Tagged With: Array

Check a String is SUBSEQUENCE of another String Find Minimum length for that ( DNA Matching )

August 12, 2014 by Dhaval Dave

Main DNA sequence(a string) is given (let say strDNA) and another string to search for(let say strPAT).
You have to find the minimum length window in strDNA where strPAT is subsequence.


Example :
strDNA =

… Read More

Filed Under: Amazon Interview Question, Flipkart Interview Questions, Interview Questions, problem Tagged With: Array, Dynamic Programming, string

Add Sub Multiply very large number stored as string

August 10, 2014 by Dhaval Dave

Very large number like 2994320121 and 125346232 is given in character string.
You need to add, subtract and multiply two numbers and store number in character array only.

Logic
1) First way to create a
… Read More

Filed Under: Amazon Interview Question, Interview Questions, Microsoft Interview Questions Tagged With: Mathematical, string

Code Chef PRGIFT Solution

August 6, 2014 by Dhaval Dave

Today is chef’s friend’s birthday. He wants to give a gift to his friend. So he was desperately searching for some gift here and there.
Fortunately, he found an array a of size n lying
… Read More

Filed Under: Flipkart Interview Questions, Interview Questions, problem Tagged With: Array, codechef

Find and print longest consecutive number sequence in a given sequence in O(n)

August 6, 2014 by Dhaval Dave

Ex: Input: 1 2 5 3 6 8 7
    Output: 5 6 7 8

As given in Above example we need to find Longest Consecutive sequence in O(n)
I have implemented in O(n) considering by

… Read More

Filed Under: Amazon Interview Question, Interview Questions, Microsoft Interview Questions, problem Tagged With: Array

Flipkart Set 1 On Campus with Answers

August 5, 2014 by Dhaval Dave

Round 1(Online):
There were 2 questions time limit 90 mins.
1. A person wants to go from origin to a particular location, he can move in only 4 directions(i.e East, West, North, South) but his
… Read More

Filed Under: Flipkart Interview Questions, Interview Experience

Find min element in Sorted Rotated Array (With Duplicates)

August 4, 2014 by Dhaval Dave

Problem: Find the minimum element in a sorted and rotated array if duplicates are allowed:
Example: { 2, 2, 2, 2, 2, 2, 2, 2, 0, 0, 1, 1, 2}   output: 0
Algorithm:

This problem

… Read More

Filed Under: Amazon Interview Question, Flipkart Interview Questions, Interview Questions, Microsoft Interview Questions Tagged With: Array, Binary Search

Find min element in Sorted Rotated Array (Without Duplicates)

August 4, 2014 by Dhaval Dave

Problem: Find the minimum element in a sorted and rotated array if duplicates not allowed:
Example: {3, 4, 5, 6, 7, 1, 2} output: 1

Algorithm:
This problem can be easily solved in O(n) time

… Read More

Filed Under: Amazon Interview Question, Flipkart Interview Questions, Interview Questions, Microsoft Interview Questions, problem Tagged With: Array, Binary Search

CodeChef Code SGARDEN

August 4, 2014 by Dhaval Dave

This time Sheriff gathered all the bandits in his garden and ordered them to line up. After the whistle all bandits should change the order in which they stand.
Sheriff gave all the bandits numbers
… Read More

Filed Under: Flipkart Interview Questions, Microsoft Interview Questions Tagged With: Array, codechef

Check Binary Tree is Binary Search Tree or not

July 29, 2014 by Dhaval Dave

To search Binary Search Tree
First lets understand characteristics of BST
• The left subtree of a node contains only nodes with keys less than the node’s key.
• The right subtree of a node
… Read More

Filed Under: Interview Questions, problem Tagged With: Binary Search Tree, Binary Tree, BST, tree

  • « Previous Page
  • Page 1
  • …
  • Page 11
  • Page 12
  • Page 13
  • Page 14
  • Page 15
  • …
  • Page 17
  • Next Page »

Primary Sidebar

Join WeekEnd Online/Offline Batch from 4-April-2020 on How to Crack Coding Interview in Just 10 Weeks : Fees just 20,000 INR

Join WeekEnd Online/Offline Batch from 4-April-2020

WhatsApp us

Secondary Sidebar

Custom Search

  • How I cracked AMAZON
  • LeetCode
  • Adobe
  • Amazon
  • Facebook
  • Microsoft
  • Hacker Earth
  • CSE Interview

Top Rated Questions

Find Pythagorean Triplets in an array in O(N)

Coin Collection Dynamic Programming

Sort Stack in place

SAP Interview Questions

Top 10 Interviews Techniqes for Campus Interview in IIT NIT BITS for MTech

Count Possible Decodings of a given Digit Sequence

N teams are participating. each team plays twice with all other teams. Some of them will go to the semi final. Find Minimum and Maximum number of matches that a team has to win to qualify for finals ?

Singly linked list

write a c program that given a set a of n numbers and another number x determines whether or not there exist two elements in s whose sum is exactly x

Print vertical sum of all the axis in the given binary tree

Walmart Labs Interview Experience

Maximum occurred Smallest integer in n ranges

Printing intermediate Integers between one element & next element of array

Rectangular chocolate bar Create at least one piece which consists of exactly nTiles tiles

Leetcode: Edit Distance

Given a sorted array and a number x, find the pair in array whose sum is closest to x

25 horses 5 tracks Find 3 fastest puzzle

Sort an array according to the order defined by another array

Practo Hiring Experience

Hackerearth : Counting Subarrays

Search element in a matrix with all rows and columns in sorted order

BlueStone E-commerce Interview Experience

Skiing on Mountains Matrix

Print all nodes that are at distance k from a leaf node

Printing Longest Common Subsequence

Password Predictor

Find if a binary tree is height balanced ?

Get Minimum element in O(1) from input numbers or Stack

Possible sizes of bus to carry n groups of friends

robot standing at first cell of an M*N matrix. It can move only in two directions, right and down. In how many ways, it can reach to the last cell i.e. (M, N) Code it

Copyright © 2025 · Genesis Framework · WordPress · Log in