Common Lisp Developer Hiring Guide

Hiring Guide for Common Lisp Engineers

Ask the right questions to secure the right Common Lisp talent among an increasingly shrinking pool of talent.

Common Lisp is a high-level, general-purpose programming language, first developed in the 1980s as a standardized version of Lisp, one of the oldest high-level programming languages. It was designed by a group of researchers led by Guy L. Steele Jr., who aimed to unify the diverse Lisp dialects into a single language. The language is known for its flexibility, allowing programmers to choose the best approach for their specific task, whether it's procedural, functional, or object-oriented. It has been widely used in artificial intelligence research and continues to be popular in academia and industry. The development and standardization of Common Lisp are documented in Steele's book, "Common Lisp the Language" and the ANSI Common Lisp standard.

First 20 minutes

General Common Lisp knowledge and experience

The next 20 minutes of the interview should attempt to focus more specifically on the development questions used, and the level of depth and skill the engineer possesses.

How would you implement recursion in Common Lisp?

Recursion in Common Lisp is implemented by having a function call itself. The function must have a condition to stop the recursion to avoid infinite loops.

Describe the difference between 'eq', 'eql', 'equal', and 'equalp' in Common Lisp.

'eq' tests if two items are the same object, 'eql' tests for the same object or equal numbers/characters, 'equal' tests for structurally similar objects, and 'equalp' tests for structurally similar objects with type conversion.

What is the purpose of the 'let' construct in Common Lisp?

'let' is used to create local variables in Common Lisp. It allows you to bind variables to values for the duration of the body of the 'let' construct.

How would you define a function in Common Lisp?

You can define a function in Common Lisp using the DEFUN macro. For example: (defun function-name (parameters) function-body)

What are the basic data types in Common Lisp?

Common Lisp has several basic data types, including: integers, floating-point numbers, characters, symbols, cons cells, arrays, hash-tables, structures, and functions.

The hiring guide has been successfully sent to your email address.
Oops! Something went wrong while submitting the form.

What youre looking for early-on

Has the candidate worked on any projects or tasks that involved Common Lisp?

This is important because it provides evidence of the candidate's practical experience with the language, and can give you insight into their problem-solving skills and ability to deliver results.

Does the candidate have experience with functional programming concepts in Common Lisp?

This is important because Common Lisp is a multi-paradigm language that includes functional programming. This indicates that the candidate can write code that is more concise, easier to test, and has fewer bugs.

Can the candidate effectively debug and optimize Common Lisp code?

This is crucial because it shows the candidate's ability to identify and fix issues in a program, and improve its performance.

Is the candidate familiar with the Lisp ecosystem and libraries?

This is important because it shows that the candidate has experience with the tools and resources commonly used in Lisp development.

How well does the candidate understand and use data structures and algorithms in Common Lisp?

This is important because it shows the candidate's ability to solve complex problems and write efficient code.

Does the candidate show a strong understanding of Common Lisp's syntax and semantics?

This is crucial because it is the basis for creating efficient and effective programs within the language.

Next 20 minutes

Specific Common Lisp development questions

The next 20 minutes of the interview should attempt to focus more specifically on the development questions used, and the level of depth and skill the engineer possesses.

Describe the difference between 'progn' and 'prog1' in Common Lisp.

'progn' and 'prog1' both execute a sequence of expressions, but 'progn' returns the value of the last expression, while 'prog1' returns the value of the first.

How would you create a class and an instance of a class in Common Lisp?

You can create a class using the 'defclass' macro and an instance using the 'make-instance' function. For example: (defclass class-name (superclasses) (slots)) and (make-instance 'class-name).

What is the Common Lisp Object System (CLOS) and what features does it provide?

CLOS is the object-oriented programming system in Common Lisp. It provides features like multiple inheritance, multimethods with multiple dispatch, and method combination.

How would you handle exceptions in Common Lisp?

Exceptions in Common Lisp are handled using the 'condition' system. You can use the 'handler-case' or 'handler-bind' forms to catch and handle exceptions.

What are macros in Common Lisp and how do they differ from functions?

Macros in Common Lisp are like functions, but they operate on the code itself at compile time, not on the runtime values. This allows for code generation and transformation before execution.

The hiring guide has been successfully sent to your email address.
Oops! Something went wrong while submitting the form.

The ideal back-end app developer

What you’re looking to see on the Common Lisp engineer at this point.

A skilled Common Lisp engineer should demonstrate deep knowledge of the language, problem-solving skills, and ability to optimize code. They should be able to discuss past projects with specificity and detail. Red flags include inability to explain complex concepts or problems they've solved, over-reliance on other questions or tools, and lack of enthusiasm for Lisp.

Digging deeper

Code questions

These will help you see the candidate's real-world development capabilities with Common Lisp.

What does this simple Lisp code do?

(defun add-numbers (x y) (+ x y))

This code defines a function called 'add-numbers' that takes two arguments, 'x' and 'y', and returns their sum.

What does the 'let' keyword do in this Lisp code?

(let ((x 5) (y 10)) (+ x y))

'let' is used to bind variables. In this code, 'x' is assigned the value 5 and 'y' is assigned the value 10. Then, their sum is returned.

What will be the output of this Lisp code that manipulates a list?

(let ((my-list (list 1 2 3 4 5))) (append my-list (list 6 7 8 9 10)))

This code will output a list from 1 to 10. It first creates a list from 1 to 5, then appends another list from 6 to 10 to it.

What does this Lisp code do related to threading?

(bt:make-thread (lambda () (format t "Hello, World!")))

This code creates a new thread that prints 'Hello, World!' to the standard output. 'bt:make-thread' is a function from the Bordeaux Threads library for multithreading in Common Lisp.

What does this Lisp code do related to class design?

(defclass person () ((name :initarg :name :accessor person-name) (age :initarg :age :accessor person-age)))

This code defines a class 'person' with two attributes, 'name' and 'age'. It also defines initializers and accessors for these attributes.

What will be the output of this Lisp code that uses recursion?

(defun factorial (n) (if (<= n 1) 1 (* n (factorial (- n 1)))))

This code defines a recursive function 'factorial'. The function multiplies 'n' by the factorial of 'n - 1' until 'n' is less than or equal to 1, at which point it returns 1. It calculates the factorial of a given number.

Wrap-up questions

Final candidate for Common Lisp role questions

The final few interview questions for a Common Lisp candidate should typically focus on a combination of technical skills, personal goals, growth potential, team dynamics, and company culture.

Describe the difference between dynamic and lexical scoping in Common Lisp.

In dynamic scoping, a variable refers to the nearest binding in the call stack, while in lexical scoping, a variable refers to the nearest binding in the source code. Common Lisp supports both, but lexical scoping is the default.

How would you create and manipulate multidimensional arrays in Common Lisp?

You can create multidimensional arrays using the 'make-array' function and access or set elements using the 'aref' function. For example: (make-array '(3 3)) creates a 3x3 array.

What is tail recursion in Common Lisp and why is it important?

Tail recursion in Common Lisp is when the recursive call is the last operation in the function. It's important because it can be optimized by the compiler to use constant stack space, preventing stack overflow.

How would you implement a loop that iterates over a list in Common Lisp?

You can use the 'dolist' macro to iterate over a list in Common Lisp. For example: (dolist (var list) body)

What are the uses of the 'format' function in Common Lisp?

The 'format' function in Common Lisp is used for formatted output. It can output to a string, a stream, or the console, and it supports a wide variety of format directives.

The hiring guide has been successfully sent to your email address.
Oops! Something went wrong while submitting the form.

Common Lisp application related

Product Perfect's Common Lisp development capabilities

Beyond hiring for your Common Lisp engineering team, you may be in the market for additional help. Product Perfect provides seasoned expertise in Common Lisp projects, and can engage in multiple capacities.