Coding Interview Tips
Coding Interview Tips
Initial Interview
Guide
Welcome to your prep guide for your machine learning (ML) initial
What You’ll Find interview at Meta. Our ML engineers and recruiters put together this
in This Guide
guide so you know what to expect and how to prepare.
Time
Interview Overview
Time
Prep Guide for Your
Initial Screen How much time can you expect to prep for and take your initial tech
screen?
What Success Looks Like
Prep Time
11 Tips for Your Initial Screen
Start your prep early. Before your interview date, be sure to spend time practicing
Appendix / Resources your coding, algorithmic, and problem-solving skills.
45 Minutes to Interview
Your conversation with an engineer will be divided into the following time blocks:
• Introductions: 5 minutes.
Let’s get to know each other. We’ll talk about us and you’ll talk about who you
are, where you’ve trained and worked, and what your areas of expertise are.
• Coding: 35 minutes.
Solve one or more coding problems focused on computer science
fundamentals like algorithms, data structures, recursions, and binary trees. If
your tech screen is by phone, the engineer will send you a collaborative editor
(such as CoderPad).
1
Interview Overview
How is your initial tech screen structured?
Your interview will be by phone with an engineer, and you’ll be coding remotely on
CoderPad, so make sure you’ve practiced using it to code. Also, check your tech so
it’s solidly operable—fully charged, good internet connection, and hands-free.
The interview is formatted to see how candidates can quickly come up with the
most efficient solution to a problem in their head first, and then quickly code it
without logic flaws. You’ll need to think of corner / edge cases before and while you
code, then check your code at the end. The coding problem is worked out by hand
on the digital whiteboard so the interviewer is able to see your thought process and
collaborate with you.
Content
The content of the screen could cover a variety of topics, but generally interviewers
want to assess your ability to develop original software in a short period of time.
Interview topics may cover anything on your resume, including:
Critical Topics:
Data Structures: Algorithms:
2
Prep Guide for Your Initial Screen
From big picture to the specifics, this is how our engineers suggest
you prepare
In general
• Do as many coding questions as you can. Go to Program Creek and review
the Top 10 algorithms for a coding interview. Try to pick a few of the classic
examples to solve by hand and from scratch on a blank sheet of paper. Time
yourself so you’re completing each question within 15 – 20 minutes. This
exercise should best prepare you with what to expect during the interview.
• Familiarize yourself with key data structures and algorithms. Really important
structures include (but are not limited to) lists, arrays, hash tables, stacks,
queues, graphs, various flavors of trees and tries, and heaps. Knowing about
balanced trees couldn’t hurt. It’s really important to know about major types
of sorts (mergesort, quicksort, radix sort, etc.), searches, and traversals (BFS,
DFS). Knowing how to find a spanning tree or a minimum cut, or knowing
about dynamic programming could be nice to have. Be able to discuss the Big
O complexity of your approaches. Definitely know when and when not to use
recursion.
More specifically…
To get a deeper sense of what we mean, visit our Meta Engineering Interview Prep
pages to see what tips engineers have for initial and onsite interviews.
Prep exercises
Take these actions to test your knowledge:
• Read the book Cracking the Coding Interview. You’ll start to notice the
solution rotates around recursion and a data structure.
• Practice real questions online like LeetCode Regular Problem Sets. Attempt
to solve medium and hard problems. You should be able to consistently get
through medium
to hard problems within 40 minutes and at an optimal complexity.
3
What Success Looks Like
Considerations that lead to a positive outcome
Interviewers will weigh the success of an interview based on the approach as
much as the answer. They’ll funnel your performance based on the following
considerations:
4. Hints.
If your interviewer gives you hints to improve your code, please run with them.
4
7. Plan your approach.
Ensure that you spend time planning your approach but remember you can
always go brute force and then optimize from there.
8. Clarifying questions.
Make sure you’re asking clarifying questions as you go along (there won’t be
tricks but ensure you have all the info you need).
10. Questions.
You’ll most likely have some time at the end for questions for your interviewer.
Some people find it easier to come up with a few questions in advance rather
than think of them on the spot.
11. Cancelling.
Don’t hesitate to cancel if something comes up. If you won’t have a quiet space, a
good internet connection, and a good phone connection, or you had to stay up all
night with a sick child or broken system, please reschedule. We want you at your
best and will be happy to move your interview to a better time.
Appendix / Resources
Links to exercises, information, and guides to help you prepare
For your initial tech screen, our engineers collected some helpful resources with
content and activities. Take a look through the list as you prepare.
Coding questions
• CareerCup: Archive of interview questions by the author of Cracking the
Coding Interview.
5
Resources from Meta
• How to Crush Your Coding Interview: A video about how to prepare for
programming interviews at Meta.
Helpful books
• Cracking the Coding Interview by Gayle McDowell. Best-known and best-
selling book about software interviews.