BuyHatke Interview Experience — July 2020

BuyHatke
1. All distinct triplets whose sum equal to 0 .2. Zigzag string Conversion3. Mark all Hamiltonian Cycle in a given graph4. Find a first non-repeating character in a stream of characters.
1.Finding a peek element in the array - Return any Element greater than it's adjacents.  Eg. [1,2,3,4,5,6,4]  output- 6

2. Given a number and integer K. Return a number after offsetting all the bits after K in the binary representation of the given number But without any kind of loop or recursion.
He was trying to ask me to do using Bit manipulation only.Eg. num-15 K=2
1111 after offsetting all the bits after K position - 0011
Output- 3

3. Given a Directed positive weighted graph with source and destination node. Return the minimum weight to reach the destination node. But its compulsory to take one or more paths in between
to reach the destination node. (In the least Complexity).

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store