Monday, April 2, 2012

Interview questions

Went to a few interview recently. Below are the questions I can remember. Compared to four years ago when I was looking for my first job, the questions this time are more conceptual in nature, and companies focus a lot more on behavior and situational questions.

C#
  • Difference between value and reference type 
  • Difference between ref and out
  • Where do you use using
  • How to use datareader
  • How to fill a dataset using data adapter
  • How to read a text file 
  • Design patterns: factory, abstract etc
  • Delegates. What's it for, when to use it.

JavaScript/jQuery
  • How to create objects in JavaScript

Database
  • Difference between IDENTITY and SCOPE_IDENTITY
  • How to know number of rows in a table
  • What's ACID
  • Define third normal form (3NF) 
  • UNION vs UNION ALL
  • A quick test on Join tables
  • paging in stored procedure
  • efficient way to send a list of id to stored procedure and parse. Passing a delimited list then use CTE for this.

WebServices and WCF
  • Where's the end-point information in WSDL file
  • How to implement a webservice using WCF. Answer: define an interface and decorate with [OperationContract] attribute, then implement the interface.