Interview Question for Software Engineer / Developers


Country: United States
Interview Type: In-Person




Comment hidden because of low score. Click to expand.
0
of 0 vote

So you weren't satisfied with the explanations you read elsewhere?

- S O U N D W A V E March 23, 2014 | Flag Reply
Comment hidden because of low score. Click to expand.
0
of 0 votes

My bad, I didn't check for duplicates before posting this, truly sorry. Don't know how to delete this question, though.

- meh March 23, 2014 | Flag
Comment hidden because of low score. Click to expand.
0
of 0 votes

And if you meant "elsewhere" as in "this is a VERY generic / simple question whose answer could be found almost anywhere", again, sorry about that. I posted this question not because I needed an answer but just as a way to say "hey, they're still asking this kind of questions in the interviews, so you better take a quick look at them since most book-implementations of the sorting algorithms work on arrays". But maybe I should only post hard / interesting questions on this website to avoid swamping readers, so yeah... sorry about that :-\

- meh March 23, 2014 | Flag
Comment hidden because of low score. Click to expand.
0
of 0 votes

You posted a facebook interview question and a non facebook interview question both on this Sunday.

- S O U N D W A V E March 23, 2014 | Flag
Comment hidden because of low score. Click to expand.
0
of 0 votes

yeah... so?

- meh March 23, 2014 | Flag
Comment hidden because of low score. Click to expand.
0
of 0 votes

@Meh: So? Were you asked these in an interview? Or just pasting them from some other site.

If you want help with preparation, post such questions in the forum.

- Anonymous March 23, 2014 | Flag
Comment hidden because of low score. Click to expand.
0
of 0 vote

For such a general question, I would implement selection sort.
Scan linked list for max (always keeping ref/ptr to previous element of current max), then place it in new linked list. Repeat until old linked list has 0 elements.

- S O U N D W A V E March 23, 2014 | Flag Reply
Comment hidden because of low score. Click to expand.
0
of 0 vote

Insertion sort.
Take the first node, put it in a new list where it belongs.

- Shiv March 25, 2014 | Flag Reply
Comment hidden because of low score. Click to expand.
0
of 0 vote

Merge Sort Can do this in O(nlogn) complexity

- Snehal Kumar January 07, 2015 | Flag Reply


Add a Comment
Name:

Writing Code? Surround your code with {{{ and }}} to preserve whitespace.

Books

is a comprehensive book on getting a job at a top tech company, while focuses on dev interviews and does this for PMs.

Learn More

Videos

CareerCup's interview videos give you a real-life look at technical interviews. In these unscripted videos, watch how other candidates handle tough questions and how the interviewer thinks about their performance.

Learn More

Resume Review

Most engineers make critical mistakes on their resumes -- we can fix your resume with our custom resume review service. And, we use fellow engineers as our resume reviewers, so you can be sure that we "get" what you're saying.

Learn More

Mock Interviews

Our Mock Interviews will be conducted "in character" just like a real interview, and can focus on whatever topics you want. All our interviewers have worked for Microsoft, Google or Amazon, you know you'll get a true-to-life experience.

Learn More