Interview Question: Matlab Command

Sample Question #301 (programming – Matlab)
 
Dude, I see you’re skilled at Matlab. Now tell me quickly: does the log function in Matlab return the natural logarithm or the common logarithm?
 
(Common log = base 10)
 
[Remembering the definitions of the log() function in different programming languages is one of the more frustrating aspects of using different languages at work]
Advertisements
This entry was posted in Sample Qs. Bookmark the permalink.

3 Responses to Interview Question: Matlab Command

  1. Brett says:

    Matlab’s log() function returns the natural log. The log10() function returns the common log.
     
    I used to be amazed at how many candidates who claimed to know Matlab didn’t know the answer to this question; and, often, I could tell whether someone knew the answer or was simply trying to guess. Sometimes I made the answer a bit harder to guess at by throwing in a third possibility: a general logarithm function.
     
    Anyway, if your resume says you know something, you’d better really know it. Quants, more than other types of people in the business world, tend to ask you the most exotic questions from fields you claim to be knowledgeable in.

  2. Alex says:

    I probably would not want to work for a company where this question was asked. Knowing syntax when you can easily look this up in the help in three seconds, is not representative of the programming skills at all. I use help all the time for such things, and consider myself a very good programmer. In the interviewer’s place, I would actually consider the correct guess a better sign then knowledge of this information…

  3. Alex, it’s not true that someone proficient in development can get away with not knowing these details. Imagine you’re giving a presentation to an important client who suddenly asks you this question even though this is not in your presentation. Quants, including quant developers, present to bosses and outside clients all the time. If you say you’re good with a tool, you’d better know 99% of its details. The log function from various programming languages is a favorite way for interviewers to test candidates who claim they’re programming experts.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s