Texas Instruments Interview Question

How would you write an efficient data structure that would represent a deck of cards.

Interview Answers

Anonymous

Feb 17, 2011

Use a CardLayout. In Java, this would be cardLayout.add(someCard); (with the appropriate initial set up).

Anonymous

Jan 7, 2010

An array