2

Possible Duplicate:
How to prepare yourself for programming interview questions?

I am going for c#-sql server job and I was looking for some link where I could download some questions and answers to have look at.Googling I have found many but because there is no download you have to click and navigate for each question and answer which makes the process very intense.

Do you know a link where I can download some good c#/sql server questions?

Also I am told I will be given a programming task.

I have no idea what that might be. I hope is not some silly math algorithm that I know I will fail or some bubble sort stuff that I have never used in my c# programming life.

Any ideas or examples people have been asked? Or is there a place where managers go to get this stuff?

It's not a case of cheating but I find some questions not really pratical in the real world.

typical silly question for a c# in my view is

What's the difference between a stack vs heap? Now tell me whether as a c# programmer you are really bothered about the stack and heap.

If you do some unboxing the compiler will tell you have an error.etc..

Why they keep asking that question.Even the agency the other day asked me that question.

thanks a lot for any suggestions

brix
  • 57

3 Answers3

4

Stack vs. heap is not a "silly" question. A .NET developer who does not know the difference is suspicious, at least. A wise programmer will be able to use this knowledge quite efficiently: detecting that some small objects won't survive after the end of the current region, allocating them on stack may increase performance significantly. Any decent .NET developer have to know what the boxing is and what's the difference between value and object types.

Turnkey
  • 1,697
SK-logic
  • 8,517
4

All this make sense only if interviewer looks for the same questions. Otherwise they can always ask you something special. You simply know the stuff or you don't. That will show if you are junior / standard / senior or expert in the field. Once company prepares their own questions and tasks you will never prepare for them (unless you have somebody who already works for the company). Separate category is programming task - that can be anything and most often it is programming on the paper which I consider as somehow more stressful.

And yes difference between stack and heap is important. It is general knowledge. General knowledge is something you usually get during university study - that is the reason why developers with university degree are sometimes more successful. If you don't have general knowledge you are just the guy who knows the programming syntax. Here you have some other questions by Scott Hanselman and you will see that general knowledge is required:

3

typical silly question for a c# in my view is

What's the difference between a stack vs heap? Now tell me whether as a c# programmer you are really bothered about the stack and heap.

You must be thinking of the stack and the heap, the two memory structures directly supported by most modern computer architectures. As a programmer, you absolutely should know that stack and heap are two types of data structures, just as you should know what a binary tree, b-tree, linked list, array, and associative array, etc. are. You should also have at least some idea of how to implement all of these, the major benefits they provide, and which is appropriate for a given situation.

You don't need to download a list of interview problems. You need to read a good book on algorithms and data structures.

Caleb
  • 39,298