Nvidia
The Hershey Company Interview Questions and Answers
There are ‘N’ people numbered from 0 to N - 1, standing in a queue. You are given two arrays ‘Height’ and ‘Infront‘ consisting of ‘N’ non-negative integers. ‘Height[i]’ gives the height o...read more
The task is to find the actual order of people in a queue based on their heights and the number of taller people in front of them.
Iterate through the given arrays and create a list of tuples containing the height and number of taller people for each person.
Sort the list of tuples in descending order of height and ascending order of the number of taller people.
Create an empty result list and insert each tuple into the result list at the index specified by the number of taller ...read more
You have been given a Binary Search Tree and a key value ‘X’, find if a node with value ‘X’ is present in the BST or not.
Note:
You may assume that duplicates do not exist in the tree.
For e...read more
The task is to find if a given value is present in a Binary Search Tree (BST).
Start from the root node and compare the value with the target value.
If the value matches, return true.
If the target value is less than the current node value, move to the left child.
If the target value is greater than the current node value, move to the right child.
Repeat the process until a match is found or a leaf node is reached.
If a leaf node is reached and no match is found, return false.
What is the use of a function pointer in C?
What is Little and Big Endian?
What does a kernel do?
Program to determine if your system is little or big endian
What is a volatile keyword?
Design data structure to implement multi threading.
More about working at Nvidia
Top Software Developer Interview Questions from Similar Companies
Reviews
Interviews
Salaries
Users/Month