Tekion
VVC MOTORS Interview Questions and Answers
Q1. Connect nodes of a tree that are on the same level
Connect nodes of a tree on the same level
Use a queue to traverse the tree level by level
For each level, connect the nodes using their next pointer
If a node has no next node, set its next pointer to null
Q2. Add two numbers represented as a linked list
Add two numbers represented as a linked list
Traverse both linked lists and add corresponding nodes
Handle carry over to next node
Create a new linked list to store the result
Q3. Left View of a binary tree
Left view of a binary tree is the set of nodes visible when the tree is viewed from the left side.
The leftmost node at each level is included in the left view.
Use depth-first search to traverse the tree and keep track of the maximum level seen so far.
If the current node is at a level greater than the maximum level seen so far, add it to the left view and update the maximum level seen.
Q4. Right view of a binary tree
The right view of a binary tree shows the rightmost node at each level.
Traverse the tree in a depth-first manner, starting from the right child of each node.
Keep track of the current level and only add the rightmost node of each level to the result.
Example: For the tree [1,2,3,null,5,null,4], the right view is [1,3,4].
Q5. Find number of 2s in a given number
Count the number of 2s in a given number
Iterate through each digit of the number and count the occurrences of 2
Convert the number to a string for easier manipulation
Handle edge cases like negative numbers or zero
Q6. Parking lot design
Parking lot design involves layout, size, capacity, and efficiency considerations.
Consider the layout to maximize space and ease of access for vehicles.
Include designated spots for different types of vehicles (e.g. compact, electric, disabled).
Implement efficient traffic flow patterns to reduce congestion and improve safety.
Incorporate technology like sensors and automated payment systems for convenience.
Ensure proper lighting and security measures for safety of vehicles and ...read more
Interview Process at VVC MOTORS
Top Associate Software Engineer Interview Questions from Similar Companies
Reviews
Interviews
Salaries
Users/Month