Forum Posts
- 0 Answers I was recently asked a algorithm question in interview at MazikPakistan
it was more of mathematical but i could not get to it...
- ameetpunshi7 September 21, 2013
Like an array A of size n...using decision tree technique prove lower bound problem on finding number of zeros in array A. :s I was like what quesiton is that :S so i just ended up sayin the lower bound will be theta(nlogn) but could not prove at that time...:S| Flag | PURGE - 0 Answers Internship interviews and job interviews
Hi, i'm a B.Tech 3rd year. Recently many companies like facebook, microsoft, samsung, amazon,directi etc visited out campus for internship recruitment. They only asked questions about algorithms and coding. What i want to know is, will the recruitment process for jobs be any different than this? I mean will they ask questions other than just asking the algorithms and coding in C++ or Will there be any questions from systems, databases etc? I read the book cracking coding interviews and it says in job interviews, most questions will be from algorithm part and they may ask about projects and a little bit of systems and other topics. But i'm not sure if they will do the same during campus interviews, can anyone please tell me if job placement interviews will be different from internship interviews?
- TheDarkKnight September 21, 2013| Flag | PURGE - 0 Answers Interview at Amazon
Hi everyone
- danielpiedrahita September 20, 2013
8 weeks ago I got a phone call from the hiring manager and he wants to give me an offer, but because of my immigration status he is looking options like send me to other location and then after one year transfer me to Seattle. because there's not more H1B visas until next year.
I'm very worried because the last time I talk with him was almost 6 weeks, I send an email to follow up the situation. but I didn't receive a reply till now. It's this mean the withdraw the offer? am I still in the process? I don't know what to think? How long I have to wait to move on?| Flag | PURGE - 0 Answers Probability
A factory produces 10 glass containers daily. It may be assumed that there is a constant probability p=0.1 of producing a defective container. Before these containers are stored they are inspected and the defectives ones are set aside. Suppose that there is a constant probability r=0.2 that a defective container is misclassified. Let X equal the number of containers classified as a defective at the end of a production day. (Suppose that all containers which are manufactured on a particular day are also inspected on that day.)
- anshul221 September 20, 2013
(1)P(X=k) = ?| Flag | PURGE - 2 Answers Interview at microsoft
Hi everyone
- muhTamer September 20, 2013
I had a Microsoft phone interview on the 6th of September and I didn't receive a reply till now. So I sent an email to my recruiter to ask her about the process, but I get an automatic reply that she will be in and out of the office starting in September-November recruiting. Is this considered a reject ???| Flag | PURGE - 0 Answers ood/oop
In a college there are various departments and subdepartments and
- vasantha.tejaswi September 19, 2013
there are some printers. There is a hierarchy for use of printers. For
example sub departments can use main department's printer. Printers are of
3 kind 1. colored laser 2. black and while laser 3. dot-matrix . Anyone
who has access to colored laser has access to other two, similarly anyone
who has access to white laser has access to dot-matrix. Write a program
which depicts this structure.| Flag | PURGE - 1 Answer codechef puzzle problem
Johnny has some difficulty memorizing the small prime numbers. So, his computer science teacher has asked him to play with the following puzzle game frequently.
- Rahul Sharma September 18, 2013
The puzzle is a 3x3 board consisting of numbers from 1 to 9. The objective of the puzzle is to swap the tiles until the following final state is reached:
1 2 3
4 5 6
7 8 9
At each step, Johnny may swap two adjacent tiles if their sum is a prime number. Two tiles are considered adjacent if they have a common edge.
Help Johnny to find the shortest number of steps needed to reach the goal state.
Input
The first line contains t, the number of test cases (about 50). Then t test cases follow. Each test case consists of a 3x3 table describing a puzzle which Johnny would like to solve.
The input data for successive test cases is separated by a blank line.
Output
For each test case print a single line containing the shortest number of steps needed to solve the corresponding puzzle. If there is no way to reach the final state, print the number -1.
Example
Input:
2
7 3 2
4 1 5
6 8 9
9 8 5
2 4 1
3 7 6
Output:
6
-1| Flag | PURGE - 1 Answer Data Structures
Real life applications of Post and Prefix evaluation?
- 4m7u1 September 12, 2013| Flag | PURGE - 1 Answer If you have an offer that you ...
If you have an offer that you have accepted, and you tell Microsoft that, they will ask you for contact details of the HR of the company whose offer you signed to contact them and ask them if its ok for Microsoft to interview you, if you dont give them details they will cancel your interview.
- Illusion September 12, 2013
Microsoft has this policy where they dont consider you as a candidate if you have signed an offer already (and they know this, you can just as easily hide it) and will ask you to re apply after 8 months.
Please be careful of what details you reveal. My personal experience, I went on site and just to come back without being interviewed because I told them I have signed an offer and the only reason why I am attending the interview is because Microsoft is the better option.| Flag | PURGE - 1 Answer Interview "red flags"
Hi,
- Miguel Oliveira September 09, 2013
In the beginning of CtCI book, Gayle talks about the case of a student which she referred but had too many "red flags".
Could you elaborate more on the "red flags"? Maybe with a few more examples of these kind of mistakes that we should avoid in an interview?| Flag | PURGE - 0 Answers strings
implement the strtok() functin in C,, the strtok() function first takes the string for the first time, then it takes a NULL value, like this
- nathalie.imseeh September 08, 2013
/* walk through the first token*/
token = strtok(str, s);
/* walk through other tokens */
while( token != NULL )
{
printf( " %s\n", token );
token = strtok(NULL, s);
}
so you must write as a source code for the strtok() in C| Flag | PURGE - 2 Answers A fun little algorithms problem
Here's a fun but simple one
- Javeed September 07, 2013
Say you are moving from terminal to terminal in an airport, using the conveyor walkways (the ones no one ever really uses). You want to find the fastest way to get to your next flight, but each walkway has a certain amount of time from when you get on till you get off that will be consumed. Switching between walkways takes time k.
At any given point, there are two available walkways (one on your left, and one on your right). Assume all walkways are the same length, they just move at different rates, so when you get off of one, you have two possible choices, left or right. If you are on left, and choose right, add k to the amount of time you take, and vice versa. For n pairs of walkways, find the fastest way to get to your next terminal.
To give some variables for you to use:
n = pairs of walkways
k = time to switch sides, assume constant regardless of walkways
l_n = the nth left walkway's time value
r_n = the nth right walkway's time value
Give it a shot.
Challenge: Find a way to get your runtime to O(n log (n)).| Flag | PURGE - 1 Answer Can I change my internship from SDET to SDE?
Hello,
- andre.azevedo September 06, 2013
I just received an offer for an internship at Microsoft as SDET. At the moment the recruiter told me, I was so excited that I did not think that what I'd really want to to is a SDE internship (although it would be good to work as SDET as well).
My question is: Is it ok to e-mail my recruiter and ask her if I can change to a SDE internship?
Thank you!| Flag | PURGE - 0 Answers Solve this problem
We call an array of integers X of size N good if it can be partitioned into 2 arrays of size n/2, say p1[ ] and p2[ ], such that p1[0] + p2[0] = p1[1] + p2[1] = p1[2] + p2[2] = ... . Given an array Y, determine the size of its largest subset which is a good array.
- crCrush September 06, 2013
Input
The first line contains the integer N (≤ 100).
The next line contains N space separated integers, which are the elements of the array X.
Output
One number which is the size of the greatest subset as mentioned in the problem statement.
Example
Input:
6
1 4 2 3 8 10
Output:
4
Explanation:
The array {1,4,2,3} is good, since you can form p1[] = {1,2} and p2[] = {4,3}. (satisfying 1 + 4 = 2 + 3)| Flag | PURGE - 2 Answers Highest number less than or equal to the given number.
Hi all,
- anup.stackoverflow September 04, 2013
How can we find the highest number less than or equal to the given number?
One options is sorting + binary search.
Complexity (sorting ->nlogn, binary search->logn) = nlogn
is thr any better method?| Flag | PURGE