National Instruments
Commercial Real Estate Co Interview Questions and Answers
Q1. Given a list of words. Given three operations find out the minimum steps to reach from source string to destination string. Basically, -----/ this is the problem with some modification. For this question I said...
read moreThe question is about finding the minimum steps to reach from a source string to a destination string using three operations.
BFS and DFS are graph traversal techniques that can be used to solve this problem.
BFS is typically used when finding the shortest path or exploring all possible paths in a graph.
DFS is useful when searching for a specific path or exploring deeply into a graph.
In this case, BFS can be used to find the minimum steps to reach the destination string.
Create ...read more
Q2. To print tree in anticlock wise direction
To print a tree in anticlockwise direction, start from the bottom left and traverse each level from right to left.
Start from the bottom left of the tree
Traverse each level from right to left
Print the nodes as you traverse
Q3. Floor value of square root of a number
Floor value of square root of a number is the largest integer less than or equal to the square root.
The floor value of square root of a number can be found using mathematical functions like floor() or integer division.
For example, the floor value of square root of 16 is 4, as sqrt(16) = 4.
For non-perfect square numbers, the floor value of square root can be calculated using approximation methods.
Q4. Find the highest floor, from where if an egg is dropped will not break. k floor building and n eggs are given.
Find the highest floor from where an egg won't break, given k floors and n eggs.
Use binary search to minimize the number of drops.
Start from the middle floor and drop the egg.
If it breaks, search in the lower half, else search in the upper half.
Repeat until the highest floor is found.
Q5. Explain object oriented concepts and design in detail.
Object-oriented concepts involve creating classes and objects to organize and structure code.
Classes define the properties and behaviors of objects
Objects are instances of classes that can interact with each other
Inheritance allows for the creation of subclasses that inherit properties and behaviors from a parent class
Polymorphism allows for objects to take on multiple forms and behave differently depending on the context
Encapsulation involves hiding the implementation detail...read more
Q6. find floor square root of number n, without using sort() function. 1<=n<=10^12
Implement a function to find the floor square root of a given number without using sort() function.
Use binary search to find the square root of the number.
Start with a low value of 0 and high value of n.
Check the middle value and adjust the range accordingly.
Repeat until you find the floor square root.
Interview Process at Commercial Real Estate Co
Top Interview Questions from Similar Companies
Reviews
Interviews
Salaries
Users/Month