Intern Interview Questions
- 0of 0 votes
Answers1. Write a program to return a max BST within a given B-tree
- A February 01, 2013 in United States| Report Duplicate | Flag | PURGE
Intern Trees and Graphs - 0of 0 votes
Answer1. Write an program to check for anagrams. Discuss different implementation. like using extra space and without using extra space.
- A February 01, 2013 in United States| Report Duplicate | Flag | PURGE
Intern Algorithm - 0of 0 votes
Answers1. What is a Hash Map..? Describe its two implementation.
- A February 01, 2013 in United States
2. Difference between Arraylist and linkedlist in JAVA.
3. Discuss issues in implementing HashMaps...collisions mainly...and how to fix them.
4. What is run-time polymorphism in JAVA..explain with example.| Report Duplicate | Flag | PURGE
Intern Java - 0of 0 votes
AnswersA solution takes 8 hours to do n independent jobs. What will you do to improvise?
- TechWorld January 25, 2013 in United States for Financial Software Developer
Follow up: Improvise on a single processor
Follow up: If N task work uses shared memory| Report Duplicate | Flag | PURGE
Bloomberg LP Intern Application / UI Design - 0of 0 votes
AnswersHow to design Hash map using array.
- TechWorld January 25, 2013 in United States for Financial Software Developer| Report Duplicate | Flag | PURGE
Bloomberg LP Intern Algorithm - 0of 0 votes
AnswerDesign a database for storing record of students.
- TechWorld January 25, 2013 in United States for Financial Software Developer| Report Duplicate | Flag | PURGE
Bloomberg LP Intern Database - 0of 0 votes
AnswersDevelop and algorithm to reverse a string keeping words intact. Example: This is a question
- TechWorld January 25, 2013 in United States for Financial Software Developer
result should be: question a is This| Report Duplicate | Flag | PURGE
Bloomberg LP Intern Algorithm - 0of 0 votes
AnswersDevelop an Algorithm to implement queue using stack
- TechWorld January 25, 2013 in United States for Financial Software Developer| Report Duplicate | Flag | PURGE
Bloomberg LP Intern Algorithm - 0of 0 votes
AnswersWith a set 'S' of 'n' numbers {a(1), ... , a(n) } , determine if S contains a 4-term arithmetic sequence with:
- kbex07 January 25, 2013 in United States
a(k) = a(i) + 2(a(j) - a(i)) and a(l) = a(i) + 3(a(j) - a(i)) ; a(i) != a(j)
where the four terms are {a(i), a(j), a(k), a(l) }.
Output boolean.
Example:
Input: 31, 8, 2, 9, 5, 6, 12, 11, 20
Output: True - because {2,5,8,11}
Recruiter tried to lead me in the direction of adapting the 3SUM alg'm to get a runtime of O(n^2(logn)).| Report Duplicate | Flag | PURGE
Intern Algorithm - 0of 0 votes
AnswersFlip a monochrome bitmap around its centre-line, where input is: char *bytes, int width, int height .
- kbex07 January 25, 2013 in United States
Example:
Input
0101 0110
1111 0011
Output
0110 1010
1100 1111| Report Duplicate | Flag | PURGE
Google Intern Algorithm - 0of 0 votes
Answera. How does OS detects a device on boot up, how does it gets to know whether it is working or faulty?
- T January 23, 2013 in United States
b. How does the device driver initialize this device (initialization, registration etc)?| Report Duplicate | Flag | PURGE
Bloomberg LP Intern - 0of 0 votes
AnswersWhat is pass by value and pass by reference?
- T January 23, 2013 in United States
a. Can a structure be passed by value?
b. Can an array be passed by value?| Report Duplicate | Flag | PURGE
Bloomberg LP Intern - 0of 0 votes
AnswersHow will you implement a T9 dictionary? (requiring only 1 look up, no partial searches meaning one keys in a name and then presses go to find it)
- T January 23, 2013 in United States| Report Duplicate | Flag | PURGE
Bloomberg LP Intern Algorithm - 0of 0 votes
AnswersHow will you tell whether a given number is a palindrome?
- T January 23, 2013 in United States
Edit: The question was for a string actually.| Report Duplicate | Flag | PURGE
Bloomberg LP Intern C - 0of 0 votes
AnswersHow will you reverse a given number? (not using "/", "&" operators)
- T January 23, 2013 in United States
For eg 756 - > 657| Report Duplicate | Flag | PURGE
Bloomberg LP Intern C - 0of 0 votes
AnswersYou have a sequence of data which tells about daily prices of a stock (of a company in some market). Given the sequence for N such days tell when should one buy and sell to maximize the profit. (for simplicity Assume you can buy only 1 stock). Prices of stock is same for a single day and you cannot buy and sell on the same day.
- vik January 23, 2013 in United States
Edit: You have to buy once only and sell once only. (I also misunderstood Q during interview that we have to tell sequence of buying and selling but it was not the question)| Report Duplicate | Flag | PURGE
Walmart Labs Intern Algorithm - 0of 0 votes
AnswersYou have a vending machine with some inventory. write a program to help vending machine tender exact change to the customer.
- praveen January 11, 2013 in United States for Bing-Appex| Report Duplicate | Flag | PURGE
Microsoft Intern - 0of 0 votes
AnswersFind successor in a BST with duplicate values allowed.
- praveen January 11, 2013 in United States for Bing-Appex| Report Duplicate | Flag | PURGE
Microsoft Intern - 1of 1 vote
AnswersReverse Linked list in parts iteratively.
- praveen January 11, 2013 in United States for Bing-Appex
ex 1->2->3->4->5->6->7->8 and if 'parts' is 3.
o/p = 3->2->1->6->5->4->8->7.| Report Duplicate | Flag | PURGE
Microsoft Intern - 0of 0 votes
AnswersLet's say you have to make changes to 1000 API's. For example, currently developers need to put a .then() just to write something to the screen; we want to remove this in simple cases, but also enable it in cases where you really do want to write something only AFTER some other action has taken place.
- panoptic.biopower December 12, 2012 in United States for Windows
These 1000 API's are split among 200 teams, and you're a product manager for one of those teams.
How do you go about pushing for this change, so that eventually all of them will be changed?
How long would it take? What is the deadline?
What if one team simply says they're far too busy?
And once the dev teams are done with the changes, what more is there to do? What should the testing team do?| Report Duplicate | Flag | PURGE
Microsoft Intern - 0of 0 votes
AnswersGiven a list of words, return a list of lists, where each list contains a group of anagrams.
- panoptic.biopower December 12, 2012 in United States
Sample Input: cat bat act tab
Sample Output: [ [ cat, act ] , [ bat, tab ] ]| Report Duplicate | Flag | PURGE
Jane Street Intern - 2of 2 votes
AnswersGiven a string we have to find first non-repeating character in the string....
- varunesh.88 December 07, 2012 in India
Example: str="aabbbccccddeffffgg";
Answer is : e| Report Duplicate | Flag | PURGE
Morgan Stanley Intern C - 0of 0 votes
AnswersWrite a function to check whether the two strings are rotation of each other or not.
Example: str1="Password" str2="ordPassw"
My Solution was.........
- varunesh.88 December 07, 2012 in India#include<stdio.h> void fn(char * str1, char * str2) { int i=0, j=0,flag=0; while(str2[i]) { if(str2[i]== *str1) { flag=1; break; } i++; } if(!flag) { printf("2nd String is not a rotation of other\n"); return; } j=i; while(str2[i]) { if( !(str2[i]==*str1)) { printf("2nd String is not a rotation of other\n"); return; } i++; str1++; } i=0; while(i<j) { if( !(str2[i]==*str1)) { printf("2nd String is not a rotation of other\n"); return; } i++; str1++; } if(*str1=='\0') printf("String are rotation of each other\n"); else printf("2nd String is not a rotation of other\n"); } int main() { char * str1="Password"; char * str2="ordPassw"; fn(str2, str1); return 0; }
| Report Duplicate | Flag | PURGE
Morgan Stanley Intern C - 0of 0 votes
AnswersPrint in spiral form as shown below
- umang.1rn09cs116 November 23, 2012 in India for Development
For n=2
3 2
0 1
For n=3
4 3 2
5 0 1
6 7 8
For n=4
15 14 13 12
4 3 2 11
5 0 1 10
6 7 8 9| Report Duplicate | Flag | PURGE
IBM Intern Coding - 0of 0 votes
AnswersHow will you remove duplicate characters in a string
- enthusiast November 15, 2012 in United States| Report Duplicate | Flag | PURGE
Amazon Intern Algorithm - 0of 0 votes
AnswersYou are given an input form such as the following
- panoptic.biopower November 01, 2012 in United States
(1, (2, 3), (4, (5, 6), 7))
Each element is either a number or a list (whose elements may also be numbers or other lists).
Output the numbers as they appear, stripped down into a single list.
E.G. (1, 2, 3, 4, 5, 6, 7)
(Complication - how does your code handle the case of ((((5)))) vs just ( 5 ) ? )| Report Duplicate | Flag | PURGE
Facebook Intern Coding - 0of 0 votes
AnswersYou are given a string that is in roman numeral format.
- panoptic.biopower November 01, 2012 in United States
Output the integer representation.
E.G. You're given XIV
Output 14.| Report Duplicate | Flag | PURGE
Facebook Intern Coding - 0of 0 votes
AnswersWhat is a HashMap? What is one advantage of using a HashMap versus a TreeMap?
- msito October 25, 2012 in United States| Report Duplicate | Flag | PURGE
Amazon Intern Java - 0of 0 votes
AnswersGiven an array of integers, find the mode and the frequency of the mode. If possible, print each number along with its frequency.
- msito October 25, 2012 in United States| Report Duplicate | Flag | PURGE
Amazon Intern Arrays Java - 0of 0 votes
AnswersIn a hash map with objects as keys,
- msito October 25, 2012 in United States
a) what method do you have to overwrite to do this?
b) how would you resolve a collision?| Report Duplicate | Flag | PURGE
Amazon Intern Data Structures Java