Today, I had a phone interview experience. I would like to share with you questions I was asked.

The interviewer called me with 10 minutes delay and started by introducing himself, his job and then he asked me to do the same…

After that, the technical part started. A GoogleDoc file was shared between the interviewer and me and I had to do coding (Java in my case) within that document.

For the first question, he wrote an the below interface in the Google doc file:

interface Counter {

public void increment();

public int lastSecond();

public int lastMinute();

public int lastHour();

public int lastDay();


Then he asked me to implement that. He explained that the code is suppose to increase the number of hit per visiting a web page (this is increment() function). However, other functions e.g., lastsecond(), lastMinute() suppose to count number of hits occurred during  the last second, minute and so on…

He also asked about the type of data structure I am going to use.

After sometime, we moved to the second question which was easier for me. The second question was adding numbers that are stored in an array. I think the following example clarifies what I mean:

2179: [ 2, 1, 7, 9 ] => [ 2, 1, 8, 0 ]

 So, as we see 2179+1=2180

This one easier and I think I did a good job on this within that limited time.