Skip to main content

Interview Questions

Review this list of 4,477 interview questions and answers verified by hiring managers and candidates.
  • "Write a function which Caesar ciphers all the strings so that the first character is "a". Use ascii code points and the modulo operator to do this. Use this function to create a hashmap between each string and the CC-a string. Then go through each key:value pair in the hashmap, and use the CC-a ciphered value as the key in a new defaultdict(list), adding the original string to the value field in the output."

    Michael B. - "Write a function which Caesar ciphers all the strings so that the first character is "a". Use ascii code points and the modulo operator to do this. Use this function to create a hashmap between each string and the CC-a string. Then go through each key:value pair in the hashmap, and use the CC-a ciphered value as the key in a new defaultdict(list), adding the original string to the value field in the output."See full answer

    Machine Learning Engineer
    Data Structures & Algorithms
    +2 more
  • "Use an index, two pointers, and a set to keep track of elements that you've seen. pseudo code follows: for i, elem in enumerate(array): if elem in set return False if i > N: set.remove(array[i-N])"

    Michael B. - "Use an index, two pointers, and a set to keep track of elements that you've seen. pseudo code follows: for i, elem in enumerate(array): if elem in set return False if i > N: set.remove(array[i-N])"See full answer

    Machine Learning Engineer
    Coding
  • "I would answer this question using MECE framework: Profit = Revenue - Costs. Revenue = # customers * price In case of the trading platform, this could be translated into avg. trading activity per user * avg. commission rate . Ask if there has been any recent change to Active users or their trading activities. Similarly, ask if the commission rate has been changed recently. Based on this information, you can then identify the problem and get to the root cause of this. Similarly with Costs. "

    Alibi M. - "I would answer this question using MECE framework: Profit = Revenue - Costs. Revenue = # customers * price In case of the trading platform, this could be translated into avg. trading activity per user * avg. commission rate . Ask if there has been any recent change to Active users or their trading activities. Similarly, ask if the commission rate has been changed recently. Based on this information, you can then identify the problem and get to the root cause of this. Similarly with Costs. "See full answer

    Product Manager
    Analytical
    +1 more
  • Intuit logoAsked at Intuit 
    1 answer

    "did well but messed up dequeue"

    Shivani N. - "did well but messed up dequeue"See full answer

    Software Engineer
    Data Structures & Algorithms
    +1 more
  • Product Manager
    Analytical
    +2 more
  • 🧠 Want an expert answer to a question? Saving questions lets us know what content to make next.

  • Meta logoAsked at Meta 
    Add answer
    Product Manager
    Product Design
  • The Trade Desk logoAsked at The Trade Desk 
    2 answers

    "Was this for a full-time role? What country"

    Qbert - "Was this for a full-time role? What country"See full answer

    Software Engineer
    System Design
  • Backend Engineer
    Data Structures & Algorithms
    +1 more
  • Amazon logoAsked at Amazon 
    2 answers
    Video answer for 'Build an image carousel that displays a sequence of images (using React.js or vanilla JS).'

    "Started by asking clarification questions regarding design constraints and desired features. Break down the into re-usable components - HeroImg and Carousel (with 3 images rendered) Code the components and managed the state for both in the parent component."

    Akshay J. - "Started by asking clarification questions regarding design constraints and desired features. Break down the into re-usable components - HeroImg and Carousel (with 3 images rendered) Code the components and managed the state for both in the parent component."See full answer

    Frontend Engineer
    Coding
  • Amazon logoAsked at Amazon 
    Add answer
    Product Manager
    Technical
  • Meta logoAsked at Meta 
    16 answers
    +12

    "Clarification: What types of jobs are we targeting? Are we talking about a broad market (like Indeed) or more focused—white-collar (LinkedIn-style) or blue-collar (gigs and tasks)? Where are we launching the marketplace—U.S. or globally? Let’s assume U.S. for now. Is this a standalone product or integrated within one of Meta’s existing platforms (Facebook, WhatsApp, Instagram)? Let’s assume it’s integrated into Facebook. Overview: Meta’s Mission: Why would Meta want to launch a"

    Kat - "Clarification: What types of jobs are we targeting? Are we talking about a broad market (like Indeed) or more focused—white-collar (LinkedIn-style) or blue-collar (gigs and tasks)? Where are we launching the marketplace—U.S. or globally? Let’s assume U.S. for now. Is this a standalone product or integrated within one of Meta’s existing platforms (Facebook, WhatsApp, Instagram)? Let’s assume it’s integrated into Facebook. Overview: Meta’s Mission: Why would Meta want to launch a"See full answer

    Product Manager
    Analytical
  • Goldman Sachs logoAsked at Goldman Sachs 
    3 answers

    "Abstract class A class that can have Abstract methods - without implementations and Concerete Methods i.e with implementation. Can have private, protected and public access modifiers. Supports Single inheritance i.e a class can extend only 1 abstract class Can have constructors Mainly used when sharing common behaviors Interface Class A collection of abstract methods ( can have static and default methods also - onwards of java 8) Public, static, final are the access"

    Sue G. - "Abstract class A class that can have Abstract methods - without implementations and Concerete Methods i.e with implementation. Can have private, protected and public access modifiers. Supports Single inheritance i.e a class can extend only 1 abstract class Can have constructors Mainly used when sharing common behaviors Interface Class A collection of abstract methods ( can have static and default methods also - onwards of java 8) Public, static, final are the access"See full answer

    Software Engineer
    Coding
    +2 more
  • Amazon logoAsked at Amazon 
    4 answers

    "For any project based questions, it is important to structure your response clearly, showcasing your thought process, technical skills, problem-solving abilities, and how your work added value. Besides the STAR method, you can also use this kind of framework: 1. Start by selecting a relevant project (related to the role) Give the project background and what specific problem it solved. 2. Align the project's objective and your role Be specific about your role: were you the le"

    Malay K. - "For any project based questions, it is important to structure your response clearly, showcasing your thought process, technical skills, problem-solving abilities, and how your work added value. Besides the STAR method, you can also use this kind of framework: 1. Start by selecting a relevant project (related to the role) Give the project background and what specific problem it solved. 2. Align the project's objective and your role Be specific about your role: were you the le"See full answer

    Software Engineer
    Behavioral
    +9 more
  • Meta logoAsked at Meta 
    4 answers
    +1

    "public class CircularBuffer { private T[] buffer; private int head; private int tail; private int size; private final int capacity; public CircularBuffer(int capacity) { this.capacity = capacity; this.buffer = (T[]) new Object[capacity]; this.head = 0; this.tail = 0; this.size = 0; } public void enqueue(T item) { if (isFull()) { throw new IllegalStateException("Buffer is full"); } buf"

    Vidhyadhar V. - "public class CircularBuffer { private T[] buffer; private int head; private int tail; private int size; private final int capacity; public CircularBuffer(int capacity) { this.capacity = capacity; this.buffer = (T[]) new Object[capacity]; this.head = 0; this.tail = 0; this.size = 0; } public void enqueue(T item) { if (isFull()) { throw new IllegalStateException("Buffer is full"); } buf"See full answer

    Software Engineer
    Data Structures & Algorithms
    +1 more
  • Meta logoAsked at Meta 
    4 answers
    +1

    "This was for embedded software engineer role and not on site"

    Srihitha J. - "This was for embedded software engineer role and not on site"See full answer

    Software Engineer
    Data Structures & Algorithms
    +1 more
  • Apple logoAsked at Apple 
    2 answers

    "While answering such a question, it is important to focus on personal growth, learning, and how the experience improved your teamwork. You want to demonstrate self-awareness, humility, and an ability to adapt. I had this experience while working on a cross-functional project that involved collaboration between the engineering and marketing teams. In the interview, I shared a story when I misjudged someone and showed unconscious bias towards due their gender, ethnicity or age. It was embarrassin"

    Malay K. - "While answering such a question, it is important to focus on personal growth, learning, and how the experience improved your teamwork. You want to demonstrate self-awareness, humility, and an ability to adapt. I had this experience while working on a cross-functional project that involved collaboration between the engineering and marketing teams. In the interview, I shared a story when I misjudged someone and showed unconscious bias towards due their gender, ethnicity or age. It was embarrassin"See full answer

    Software Engineer
    Behavioral
  • Product Manager
    Product Strategy
  • Amazon logoAsked at Amazon 
    1 answer

    "input_logs = [ f"{senderid} {receiverid} {transaction_count}" "1 2 2", "3 2 42", "2 2 22", "1 1 12", "2 1 1", "2 5 4", "4 2 15" ] input_threshold = 20 exptected_output = [ list of user_ids that made more than 20 transactions sorted by number of transactions in descending order "3", # 42 transactions "2", # 27 transactions (22 + 1 + 4) #"4", # 15 transactions #"1" # 14 transactions (2 + 12 + 1) ] def gettopapi_users(logs, thres"

    Anonymous Unicorn - "input_logs = [ f"{senderid} {receiverid} {transaction_count}" "1 2 2", "3 2 42", "2 2 22", "1 1 12", "2 1 1", "2 5 4", "4 2 15" ] input_threshold = 20 exptected_output = [ list of user_ids that made more than 20 transactions sorted by number of transactions in descending order "3", # 42 transactions "2", # 27 transactions (22 + 1 + 4) #"4", # 15 transactions #"1" # 14 transactions (2 + 12 + 1) ] def gettopapi_users(logs, thres"See full answer

    Software Engineer
    Data Structures & Algorithms
    +1 more
  • Amazon logoAsked at Amazon 
    1 answer

    "Count items between indices within compartments compartments are delineated by by: '|' items are identified by: '*' input_inventory = "*||||" inputstartidxs = [1, 4, 6] inputendidxs = [9, 5, 8] expected_output = [3, 0, 1] Explanation: "*||||" 0123456789... indices ++ + # within compartments ^ start_idx = 1 ^ end_idx = 9 -- - # within idxs but not within compartments "*||||" 0123456789... indices "

    Anonymous Unicorn - "Count items between indices within compartments compartments are delineated by by: '|' items are identified by: '*' input_inventory = "*||||" inputstartidxs = [1, 4, 6] inputendidxs = [9, 5, 8] expected_output = [3, 0, 1] Explanation: "*||||" 0123456789... indices ++ + # within compartments ^ start_idx = 1 ^ end_idx = 9 -- - # within idxs but not within compartments "*||||" 0123456789... indices "See full answer

    Software Engineer
    Data Structures & Algorithms
    +1 more
Showing 1321-1340 of 4477