<iframe src="https://www.googletagmanager.com/ns.html?id=GTM-KVGHS6G" height="0" width="0" style="display:none;visibility:hidden"></iframe>

Amazon计算机科学面试真题

职位分类
全部
数据相关
计算机科学
人工智能
产品经理
BQ
面试题
全部(324)
OOD(32)
Algorithm(204)
System Design(63)
高频题(0)
Math(0)
全部(324)
OOD(32)
Algorithm(204)
System Design(63)
高频题(0)
Math(0)
1.arraylist
2.implement linked list
3.Find Kth Smallest Pair Distance in Array
4.Basic Calculator Implementation Without Eval Function
5.Minimum Number of Conference Rooms Required
6.Integer to Roman Numeral Conversion
7.Conway's Game of Life: Next State Calculation
8.Top K Frequent Words in Array
9.Return k-1 distinct characters
10.The heaviest goods
11.Location of downbell
12.Return the next letter
13.API return
14.Number of categories
15.Distance K Nodes in Binary Tree
16.remove k elements
17.Merge Intervals
18.Merging Two Sorted Linked Lists
19.Counting Primes Less Than N
20.Finding Peak Element in an Array with Binary Search
21.Minimum Buses to Reach Destination
22.Course Schedule II
23.Minimum Cost to Connect Sticks
24.mininum swaps
25.Degian a Car Radio System
26.Total imbalance
27.Find the number of ways to select pages
28.Binary Tree Level Order Traversal II
29.Binary Tree Level Order Traversal
30.Unique Permutations of a Number Collection with Duplicates
31.最少搬运次数
32.Merge k Sorted Linked Lists
33."Find User Website Visit Pattern with Highest Score"
34.Binary Tree Level Order Traversal II
35.Answered subject
36.Warehouse
37.Sum of similarities of string
38.Minimum Path Sum
39.Maze
40.Day change(cell growth)
41.Shorted job first
42.Binary search tree minimum sum from root to leaf
43.Loop in linked list
44.Insert into cycle linked listt
45.Rotate Matrix
46.Round Robin
47.LRU Cache count miss
48.Greatest Common Divisor
49.Window sum
50.Overlap Rectangle
51.Find K Nearest Point
52.Two Sum
53.Subtree
54.Reverse second half of linked list
55.Merge Two list
56.Longest palindromic substring
57.Valid parenthesis
58.Percentile
59.Linux command
60.Locker
61.Collection of expressions
62.Publishing-substrings count
63.Find array size
64.Max Frequency Element with K Increments
65.Longest Palindromic Substring in a String
66.Find Longest Path in DAG
67.Design a Email System
68.Implement a stack with O(1) time complexity for push, pop, top, and retrieve minimum element operations.
69.Lowest Common Ancestor of Two Nodes with Multiple Children
70.Identify Repeat Customers from Log Data
71.Design a Weather Report System
72.Amazon Warehouse Robot
73.Top K from Stream
74.Game Round Passing Rule Design
75.LinkedList Easy Manipulation
76.Algorithm Problem Solvable with Sliding Window and Queue
77.Deepest Node Variation
78.Top K Frequent Elements Variation
79.Implement an Interval Interface
80.Zigzag Problem
81.Count Subsequences Greater Than Another String
82.Maximum Score from Parentheses String
83.System Design Example
84.Technical Interview Questions - Medium Level Followup
85.Technical Interview Questions - Easy Binary Tree
86.Design a game similar to the 'San Si Ba' on the problem-solving website
87.Maximum Sum of Strictly Increasing Subsequence
88.Load Balancer Design
89.Minimize Errors in a Binary String with Unknown Characters
90.Course prerequisites problem
91.Design A Unique ID Generator In Distributed Systems
92.Design a Parking Lot System
93.Detecting a Square of Size 'k' in a 2D Array
94.Design a Load-Balancing Algorithm
95.Array Element Transformation Problem
96.Game Life Consumption Problem
97.Word Search
98.Optimize Time Complexity
99.System Design
100.Object-Oriented Design and Factory Pattern
101.System Design Based on Team's Work
102.Implement a Data Class with Subfunctions
103.Design a COVID Contract Tracing System
104.Coding Question: Tree Breadth-First Search
105.K Closest Points to Origin
106.Constructing a Sequence with Alternating Monotonic Subsequences
107.Optimal Parentheses Matching
108.Count Unique Pairs with Given Sum
109.Optimal Allocation of Entries
110.Underlying Data Structure of HashMap
111.Jump Game with Follow-up
112.Island Problem Variation
113.Finding the maximum score with the smallest string length.
114.Improving time and space complexity.
115.Optimizing a function for sustainability.
116.Maximize EfficiencyScore with Parentheses Perfection Kit
117.Maximize Information Gain with Permutations
118.Print Path from Root to Leaf with the Largest Sum
119.Merge K Sorted Lists
120.Max Difference of Picked Numbers
121.Optimal Memory Read
122.Maximize Parentheses Efficiency Score Problem
123.Double Linked List Data Structure Problem
124.Counting Secured Variations of Passwords
125.Maximum Sum of Pages Read from Singly-Linked List
126.Minimum Flips to Make a Happy Coin Collection
127.Subarray Sum Equals Target
128.Coding Problem Involving Depth-First Search (DFS)
129.Implement an LRU Cache
130.Find the Smallest Attractive Integer Greater than Given Code
131.2D Graph Problem Using Depth-First Search
132.Optimal Solution Discussion for a Medium Level LC Problem
133.OOD System Design for Amazon Delivery Locker System
134.Write a class to help count the occurrence of a list of characters within a list of books
135.Custom Sort String
136.Password Similarity Check
137.Marshalling and Unmarshalling Employee Structure
138.Coding Interview on Game-like 2-D Grid Problem
139.Coding Interview with Hiring Manager
140.System Design Interview
141.Front-end Coding Follow-up: Handling Exceeding Thumbnail Index
142.Front-end Coding Challenge: Amazon Image Thumbnail Switcher
143.Special Anagrams from DNA Sequences
144.Symmetrical Name Encoding Algorithm
145.Discuss your experience with object-oriented programming and how you construct OOP in your familiar language.
146.Design a Dog Day Care System
147.Design a rate limiter that functions as a distributed cache.
148.Discuss an experience where you dealt with a challenging bug.
149.Object-Oriented Design - Parking Lot
150.Course Scheduling Problem
151.Disintegrate Stones Problem
152.Low Level Design - Object and Subclass Messaging
153.Print Categories and Siblings
154.Design HashMap
155.Vote Storage Strategies Evaluation
156.Maximizing Positive Cumulative Monthly Financial Returns
157.Finding Employee Skill Pairs Within a Skill Range
158.Object-Oriented Design: API Design for a Song Search Functionality
159.Object-Oriented Design Questions
160.Word Ladder Problem
161.Design a website/system for internal employee training videos
162.Maximum Rectangle Area Using Array Elements
163.Minimum Removals to Ensure No Subsequence Sum Exceeds Threshold
164.Object-Oriented Design Clarification
165.Graph Traversal Using BFS
166.Extract Unique Web Addresses from a Page
167.String to Integer (atoi)
168.Longest Common Prefix
169.System Design: Online Chatting
170.Number of Ways to Group Parcels
171.Counting Redundant Substrings
172.Coding and Behavioral Questions
173.Hotel Booking System Design
174.Design an airplane boarding and deboarding system
175.Merge K Sorted Iterators
176.Find the Closest Common Manager
177.Design a Building Layout
178.Coding Problem
179.Object-Oriented Design
180.Complex System Design
181.Explain a time when you had to debug a technical issue.
182.Optimizing Cart Operations Using Data Structures
183.Design a class to find continuous empty seats on an airplane
184.Island Counting Algorithm
185.Describe the most complex architecture you have worked on.
186.Object-Oriented Design
187.Domain Knowledge Questions
188.Coding Problem Clarity
189.UI Component Implementation
190.HTML and JavaScript Fundamentals
191.Course Schedule II Problem
192.LRU Cache Implementation
193.Designing a Tiny URL System
194.OOP Design: Parking Lot System
195.Find Maximum Balanced Shipments
196.Make Power Non-Decreasing
197.Task Queue with Timeout
198.Reverse Binary String
199.Construct a Palindrome
200.Grouping Players by Nickname
201.Distributed Algorithm for Stock Trading
202.Maximize Median of Processed Packets
203.Object-Oriented Design
204.Minimum Total Errors Problem
205.Reduce Gift Problem
206.Design a variation of the LRU Cache
207.Server Reliability Drill
208.Reverse String With Minimum Shifts
209.Regular Expression String Validation
210.Minimum Steps to Convert Binary Representation
211.Make Power Non Decreasing
212.System Design: Instagram
213.Algorithm Design with APIs
214.Front-end Component Coding: Carousel
215.Front-end Component Coding: Menu System
216.Software Update in N-ary Tree
217.Suitable Warehouse Location
218.Server Vulnerability Analysis
219.Coin Change Problem
220.Word Ladder Problem
221.Topological Sort: Course Scheduler
222.System Design: Hospital Portal
223.Design an Image Sharing Service
224.Print Number in English
225.URL Access Frequency Problem
226.String Processing Problem
227.Monkey Eating Bananas Problem
228.Design a Stack
229.Alternative Methods for String Sorting
230.Design a Distributed Cache System
231.Implement a Class for Data Tracking
232.Implement a function `getElementByStyle`
233.Calculate Cumulative Bandwidth Usage
234.Video Upload and Download System Design
235.Robot Package Delivery Optimization
236.Minimum Hours to Update Servers
237.LRU Cache Implementation
238.Shopping Cart Management
239.Regular Expression Matching
240.System Design Communication
241.Coding Test Case Writing
242.Stock Trading Problem
243.Two Sum Problem
244.Pathfinding in a Two-Dimensional Matrix
245.Implement a 'Like' Button
246.Create an Accordion
247.JavaScript Form Validation
248.Find File in a File System with Multiple Constraints
249.Design a Messaging System Like WhatsApp
250.Reverse a Linked List in Groups of K Nodes
251.System Design for Video Streaming Service
252.Graph Connectivity Using DFS
253.Design a Password Generator
254.Find the Most Visited n-Consecutive Page Sequence
255.Design Components for Storing Chatbot Responses
256.Calculate the Number of Unique Binary Trees
257.Design a Preference Service
258.Optimize Java TreeMap Solution for Fixed-Size Subarray Ranking
259.Kindle Progress Synchronization System Design
260.Coding: Sort K Lists and Average K Lists
261.Object-Oriented Design for CSV File Format Verification
262.Design a Twitter-like System Focusing on New Tweet Functionality
263.Find the Kth Smallest Sum from Two Arrays
264.Object-Oriented Design for a File System
265.Implement a Trie Data Structure
266.System Design: Warehouse and Product Delivery Status
267.Optimal Transportation Hub Location
268.Binary Search Implementation
269.Object-Oriented Design for JSON to XML Converter
270.Finding Shared Manager in Company Org Chat
271.System Design for URL Shortening Service
272.Direct and Transitive URL Link Detection
273.Cheat Sheet for Coding Interviews
274.Find Maximum Balanced Shipments
275.Maximum Number of Balanced Shipments
276.Minimum Sum of Increased Subarray Elements
277.Optimizing solutions with complexity analysis
278.Optimizing solutions with complexity analysis
279.System Design: Simplified URL Shortening Service
280.Lowest Common Ancestor of a Binary Tree
281.Solve the 'Unique Path Sum II' problem using dynamic programming.
282.Modified Number of Islands Problem
283.System Design for a Video Streaming Service
284.Object-Oriented Design of Linux Find Command with Filters
285.Minimum Path Sum Problem with Path Printing
286.Design a Parking Lot System
287.get Max Points From Sprints
288.Implement a function similar to Promise.all
289.Deploy code for a newspaper system
290.Design a gaming room layout and implement Tic Tac Toe
291.Format JSON
292.Implement a list using your preferred framework
293.Maximize Area by Forming Rectangles from Array Elements
294.Find the Head of the Maximum Descending Subsequence in a LinkedList
295.What technologies can handle a large number of requests and how would you implement them?
296.Explain the space and time complexity of using an unordered map in your solution.
297.Longest Match in a String with Wildcard
298.getMinDistance Algorithm
299.System Design for Detecting Damaged Goods in a Warehouse
300.LeetCode 767
301.Maximum Number of Balanced Shipments
302.Find All Anagrams in a String
303.Find all paths in a tree that sum to a given value
304.Cache and Storage Management in Operating Systems
305.Dictionary Operations Time Complexity
306.Binary Search Time Complexity
307.Search for a string in all files under a UNIX directory
308.Implement an LRU Cache
309.Implement the 'Plant Flowers' algorithm.
310.Validate and optimize a Sudoku solver
311.Design a Tic-Tac-Toe game
312.Design a Book class with character index
313.Print the top view of a tree
314.Implement n-way cache
315.Coding Problem: LeetCode 113 - Path Sum II
316.Design a Text Editor
317.Merge Overlapping Intervals
318.Data Structure Comparison
319.Python Basic Usage
320.Coding Problem: Most Common Letters in Queues
321.Write a function to determine if it's possible to travel from one point to another in a 2D boolean array using BFS/DFS.
322.Explain the differences between C and Python.
323.Filter Pattern and Chain of Responsibilities
324.Implement a Web Crawler
1. arraylist
给一个arraylist<int>你可以对这个array的某一个range的数加一个数值,然后使得这个array变成一个连续上升的array(也可以等于)也就是说array[i]>=array[i-1]return每次操作的加数的和,使得这个和最小
比如[3,4,1,6,2]变成[3.4.4.9.5]然后加4变成[3.4.4.9.9]这样return7就好,当然你也可以在array[2]加3然后array[4]加4这样操作结果也是7
eg2.[3,2,1] return 2            eg 3[3,5,2,3] return 3
2. implement linked list
给你一个链表,以及一个list,list里面每个元素长度为2,第一个是当前的操作,共有三种,push head,push tail,pop head.第二个是假如操作是要push进链表,所需Push进去Node的值,要求在O(1)的空间完成
3. Find Kth Smallest Pair Distance in Array
The distance of a pair of integers a and b is defined as the absolute difference between a and b.

Given an integer array nums and an integer k, return the kth smallest distance among all the pairs nums[i] and nums[j] where 0 <= i < j < nums.length.

 

Example 1:

Input: nums = [1,3,1], k = 1
Output: 0
Explanation: Here are all the pairs:
(1,3) -> 2
(1,1) -> 0
(3,1) -> 2
Then the 1st smallest distance pair is (1,1), and its distance is 0.

Example 2:

Input: nums = [1,1,1], k = 2
Output: 0

Example 3:

Input: nums = [1,6,1], k = 3
Output: 5

 

Constraints:

  • n == nums.length
  • 2 <= n <= 104
  • 0 <= nums[i] <= 106
  • 1 <= k <= n * (n - 1) / 2
4. Basic Calculator Implementation Without Eval Function
Given a string s representing a valid expression, implement a basic calculator to evaluate it, and return the result of the evaluation.

Note: You are not allowed to use any built-in function which evaluates strings as mathematical expressions, such as eval().

 

Example 1:

Input: s = "1 + 1"
Output: 2

Example 2:

Input: s = " 2-1 + 2 "
Output: 3

Example 3:

Input: s = "(1+(4+5+2)-3)+(6+8)"
Output: 23

 

Constraints:

  • 1 <= s.length <= 3 * 105
  • s consists of digits, '+', '-', '(', ')', and ' '.
  • s represents a valid expression.
  • '+' is not used as a unary operation (i.e., "+1" and "+(2 + 3)" is invalid).
  • '-' could be used as a unary operation (i.e., "-1" and "-(2 + 3)" is valid).
  • There will be no two consecutive operators in the input.
  • Every number and running calculation will fit in a signed 32-bit integer.
5. Minimum Number of Conference Rooms Required
Given an array of meeting time intervals intervals where intervals[i] = [starti, endi], return the minimum number of conference rooms required.

 

Example 1:

Input: intervals = [[0,30],[5,10],[15,20]]
Output: 2

Example 2:

Input: intervals = [[7,10],[2,4]]
Output: 1

 

Constraints:

  • 1 <= intervals.length <= 104
  • 0 <= starti < endi <= 106

follow up :输出类似每节课对应哪个room.