Meta计算机科学面试真题

职位分类
全部
数据相关
计算机科学
人工智能
产品经理
BQ
面试题
全部(141)
OOD(2)
Algorithm(91)
System Design(28)
高频题(1)
Math(0)
全部(141)
OOD(2)
Algorithm(91)
System Design(28)
高频题(1)
Math(0)
1.Kth Largest Element in an Array
2.Diameter of Binary Tree
3.Design a wearing tracking device
4.help users find handymen
5.Design a new FB feed
6.Asteroid Collision Problem
7.Shortest Clear Path in Binary Matrix
8.Populating Next Right Pointers in Each Node II
9.Binary Tree Vertical Order Traversal
10.Telephone Number to Letter Combinations
11.Binary Tree Vertical Order Traversal
12.Binary Tree Right Side View
13.Find Kth Smallest Element in a Sorted Matrix
14.Coin Change 2
15.Generate All Combinations of Well-Formed Parentheses
16.Generating All Subsets of a Unique Element Array
17."Checking if a String is a K-Palindrome"
18."Check if String Can Be Palindrome After At Most One Deletion"
19.Minimum Area Rectangle With Points on X-Y Plane
20.Find Lexicographically Largest Permutation with One Swap
21.Determining if a Number is Strobogrammatic
22.Remove All Adjacent Duplicates in String
23.Diagonal Traverse of a Matrix
24.Find Kth Smallest Element in Sorted Matrix
25.Longest Common Prefix in Array of Strings
26.Complete Binary Tree Inserter Algorithm
27."Check if Two Halves of a String Have the Same Number of Vowels"
28."Simulating Dominoes Falling"
29.Third Distinct Maximum Number in Array
30.Check if Binary Tree is Height-Balanced
31.Flatten Nested List Iterator
32.Count Subarrays with Product Less than K
33.Sorted Squares of a Non-Decreasing Array
34.Validating Binary Search Tree
35.Is_Number_Ugly
36.Balance a Binary Search Tree
37."Minimum Rotations to Unlock a Combination Lock"
38.Finding the Lowest Common Ancestor of Deepest Leaves in a Binary Tree
39.Remove Invalid Parentheses
40.Find Kth Largest Element in an Array
41.Find Kth Largest Element in an Array
42.Simplify Unix Style Absolute Path
43.Minimum Remove to Make Valid Parentheses
44.Binary Tree Right Side View
45.Making A Large Island
46.Palindrome Validation for Alphanumeric Strings
47.Print All Paths Using Backtracking
48.Search from Top Left to Bottom Right and Print Path
49.Tree Diameter with Multiple Nodes
50.Valid Number without 'e' Version
51.Group Anagrams
52.Merge Sorted Array
53.Valid Palindrome II
54.Linux Path Command Simulation
55.Top K Songs System Design
56.Permutations of K Numbers out of N
57.Populating Next Right Pointers in Each Node
58.Find the Peak Element in a Sequence
59.Merge Three Sorted Sequences
60.Debug a given program
61.Write a program to check if the system is little endian
62.Explain little endian and big endian data formats
63.Explain the 'static' and 'volatile' keywords in programming
64.Discuss Interrupts and ISR (Interrupt Service Routine)
65.Describe the SPI communication protocol
66.Explain the I2C communication protocol and its pins
67.Simplified Version of the 'Wandering Ring' Problem
68.Find the Subtree with the Maximum Sum in a Binary Tree
69.String Serialization
70.Consecutive 1s in a Binary Array
71.Shortest Path with BFS
72.Find the Top K Elements
73.Implement the 'cd' Command
74.Design a Reminder System for Facebook Events
75.Placeholder Expansion System
76.Sorted Circular Linked List Insertion
77.System Design for an Online Gaming Platform with Ad Click Calculation
78.Simplify a String Using a Greedy Stack-Based Approach
79.Largest Number by Rearranging Digits
80.Design a Search Feature for Facebook Posts
81.Maximum Simultaneous Subtrees in a Burning Binary Tree
82.Find the Index of the Largest Number in an Array
83.System Design: Ticket Booking System
84.Multiply Two Strings
85.Add Two Strings
86.Design Ticketmaster
87.Add Two Numbers Represented as Strings
88.Maximum Perimeter Island in a 2D Matrix
89.Linux 'cd' Command Implementation
90.Lowest Common Ancestor with Parent Node
91.Top K Frequent Elements in an Array
92.String Combination to Form Target
93.Extract Prefixes from List of Strings
94.Maximum Nested Parentheses
95.Design Google Drive
96.Design an Online Auction System
97.Design a Web Crawler
98.Basic Calculator Implementation
99.Implement the 'cd' Command in Linux
100.Minimum Deletions for Valid Parentheses
101.Design a Photo Feed App/System
102.Design an Online Competition System
103.Merge Three Sorted Integer Arrays
104.System Design: Online Coding Contest
105.Next Minimum Palindrome
106.What to do if encountering the same coding problem in two rounds of interviews?
107.Merge Two Sorted Arrays
108.Optimizing Performance in Technical Solutions
109.Graph Traversal with BFS
110.Two Pointers Technique with Memory Optimization
111.Merge Intervals Problem
112.Mouse Maze Problem
113.Alternative Solution Without Using Stack
114.Design a Game for Millions of Concurrent Users
115.Probability Function Based on Array Elements
116.Implement an Event Counter
117.Implement a Simple Calculator
118.Design an Unordered Set
119.Find a Local Peak Element
120.Palindrome with At Most K Removals
121.Palindrome with At Most One Removal
122.Merge Sorted Array
123.Valid Word Abbreviation
124.System Design for a Chess Game
125.Print a Tree in Specific Order
126.Minimum Round-Trip Ticket Cost
127.Lowest Common Ancestor in a Multi-Child Tree
128.Convert a Binary Search Tree to a Balanced Binary Search Tree
129.Implement the 'atoi' function
130.1D Candy Crush Problem
131.Ancestor Query with Parent Pointer
132.Count Target Occurrences in a Sorted Array
133.Basic Calculator Implementation Without Division and Subtraction
134.Alien Dictionary
135.One Swap to Sort Array
136.Design Yelp System
137.System Design for Ads Aggregation
138.Copy a linked list with a random pointer
139.Design a service to count the number of '1's in a range within a stream of 0s and 1s
140.Task Execution Time with Cool Down Period
141.Division Without Using Division or Modulus Operators
1. Kth Largest Element in an Array
Given an integer array nums and an integer k, return the kth largest element in the array.
Note that it is the kth largest element in the sorted order, not the kth distinct element.
You must solve it in O(n) time complexity.
2. Diameter of Binary Tree
Given the root of a binary tree, return the length of the diameter of the tree.
The diameter of a binary tree is the length of the longest path between any two nodes in a tree. This path may or may not pass through the root.
The length of a path between two nodes is represented by the number of edges between them.
3. Design a wearing tracking device
Design a wearing tracking device, what are the success metrics, how do you make trade-off decisions 
4. help users find handymen
 Design a product that can help users find handymen. Assume this is for a start-up and that Facebook does not exist. Need to launch it in 6 months - what's the MVP? 
5. Design a new FB feed
Design a new FB feed where you can find nearby businesses like bars and coffee shops.