Interview Question

Senior Software Engineer Interview San Mateo, CA

Implement a sparse matrix Java class with a constructor

  , set and get method. The matrix has millions of rows and columns and is at a maximum 15% populated.
Tags:
java, data structures, algorithm
Answer

Interview Answer

1 Answer

0

Just Google the problem... In fact, the interviewers asked me if I had ever implemented this problem, and they were ready to switch to another one if I had answered yes.
I used a Hashmap in the solution and wish I had had more of the API calls for these at the ready. Practice probably helps too.

Interview Candidate on Jul 27, 2009

Add Answers or Comments

To comment on this Question, Sign In with Facebook or Sign Up