Software Engineer Interview Questions

Review this list of 438 software engineer interview questions and answers verified by hiring managers and candidates.
  • Microsoft logoAsked at Microsoft 

    "Let me try to explain it with simple life analogy You're cooking dinner in the kitchen. Multithreading is when you've got a bunch of friends helping out. Each friend does a different job—like one chops veggies while another stirs a sauce. Everyone focuses on their task, and together, you all make the meal faster. In a computer, it's like different jobs happening all at once, making stuff happen quicker, just like having lots of friends helping makes dinner ready faster."

    Praveen D. - "Let me try to explain it with simple life analogy You're cooking dinner in the kitchen. Multithreading is when you've got a bunch of friends helping out. Each friend does a different job—like one chops veggies while another stirs a sauce. Everyone focuses on their task, and together, you all make the meal faster. In a computer, it's like different jobs happening all at once, making stuff happen quicker, just like having lots of friends helping makes dinner ready faster."See full answer

    Software Engineer
    Data Structures & Algorithms
    +1 more
  • Meta (Facebook) logoAsked at Meta (Facebook) 

    "I tried solving this question and here is the recorded video for the entire solution - https://youtu.be/G_LIbTp58XA Feel free to comment here or on the video for further discussion."

    Rjj - "I tried solving this question and here is the recorded video for the entire solution - https://youtu.be/G_LIbTp58XA Feel free to comment here or on the video for further discussion."See full answer

    Software Engineer
    System Design
    +1 more
  • Meta (Facebook) logoAsked at Meta (Facebook) 
    +8

    "This is a great question! If you don't mind, I'd love to list 3 strengths and weaknesses then dive a little deeper on one of each of them. I think my three greatest strengths are: Empathy Openness to feedback Drive And three weaknesses I have been working to strengthen are: Sometimes my desire to achieve can put me at risk of overcommitting Communicating status to the right stakeholders at the appropriate time Creating detailed and strategic lists of priorities so I can meet th"

    Adam M. - "This is a great question! If you don't mind, I'd love to list 3 strengths and weaknesses then dive a little deeper on one of each of them. I think my three greatest strengths are: Empathy Openness to feedback Drive And three weaknesses I have been working to strengthen are: Sometimes my desire to achieve can put me at risk of overcommitting Communicating status to the right stakeholders at the appropriate time Creating detailed and strategic lists of priorities so I can meet th"See full answer

    Software Engineer
    Behavioral
    +3 more
  • Apple logoAsked at Apple 

    "General response: Apple’s approach to delivering seamless, personalized experiences through data, while upholding a strong ethical commitment to privacy, resonates with my own values. I want to contribute to projects that optimize user engagement and create meaningful interactions on a large scale, and I believe Apple is the ideal place to make that impact. Tailored to the team: Talk about the product, its impact internally, and the customer."

    Arshia I. - "General response: Apple’s approach to delivering seamless, personalized experiences through data, while upholding a strong ethical commitment to privacy, resonates with my own values. I want to contribute to projects that optimize user engagement and create meaningful interactions on a large scale, and I believe Apple is the ideal place to make that impact. Tailored to the team: Talk about the product, its impact internally, and the customer."See full answer

    Software Engineer
    Behavioral
    +2 more
  • Amazon logoAsked at Amazon 

    "One time at Lifetime Fitness 2019, One student was throwing a lot of towels in the counter which made things very disorganized, then I made a compromise with my coworker to put 2 towels at a time and then it worked well because it made the workspace very organized."

    Amparo L. - "One time at Lifetime Fitness 2019, One student was throwing a lot of towels in the counter which made things very disorganized, then I made a compromise with my coworker to put 2 towels at a time and then it worked well because it made the workspace very organized."See full answer

    Software Engineer
    Behavioral
  • 🧠 Want an expert answer to a question? Saving questions lets us know what content to make next.

  • Capital One logoAsked at Capital One 

    "C++ : vector justifywords(const vector& wordslist, int width) { vector result; string curr_line = ""; for (const string& word : words_list) { if (currline.length() + word.length() + (currline.empty() ? 0 : 1) > width) { result.pushback(currline); curr_line = ""; // Reset current line } if (!curr_line.empty()) { curr_line += " "; } curr_line += word; } if"

    Anonymous Basilisk - "C++ : vector justifywords(const vector& wordslist, int width) { vector result; string curr_line = ""; for (const string& word : words_list) { if (currline.length() + word.length() + (currline.empty() ? 0 : 1) > width) { result.pushback(currline); curr_line = ""; // Reset current line } if (!curr_line.empty()) { curr_line += " "; } curr_line += word; } if"See full answer

    Software Engineer
    Coding
  • Meta (Facebook) logoAsked at Meta (Facebook) 
    +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
    Coding
    +1 more
  • Visa logoAsked at Visa 
    Software Engineer
    System Design
  • Goldman Sachs logoAsked at Goldman Sachs 
    Software Engineer
    System Design
  • Dropbox logoAsked at Dropbox 

    "performance issues and sudden spikes on input requests by scaling techniques and optimization."

    Srini K. - "performance issues and sudden spikes on input requests by scaling techniques and optimization."See full answer

    Software Engineer
    Technical
    +5 more
  • Amazon logoAsked at Amazon 
    Video answer for 'Describe an experience working in a cross-functional team.'
    Software Engineer
    Behavioral
    +3 more
  • Amazon logoAsked at Amazon 
    +3

    " The Situation A few months ago, our trading platform started experiencing significant latency issues during peak trading hours. This latency was affecting our ability to process real-time market data and execute trades efficiently, potentially leading to substantial financial losses and missed opportunities. Identifying the Problem The first step was to identify the root cause of the latency. I organized a team meeting with our data engineers, DevOps, and network specialists to gather"

    Scott S. - " The Situation A few months ago, our trading platform started experiencing significant latency issues during peak trading hours. This latency was affecting our ability to process real-time market data and execute trades efficiently, potentially leading to substantial financial losses and missed opportunities. Identifying the Problem The first step was to identify the root cause of the latency. I organized a team meeting with our data engineers, DevOps, and network specialists to gather"See full answer

    Software Engineer
    Behavioral
    +3 more
  • Microsoft logoAsked at Microsoft 

    "Ask my manager how urgent is my task and why it should be done if needed. If its urgent enough and I can’t wait, communicate with team explaining what goals going to be achieved by implementing and why its important"

    Anonymous Starfish - "Ask my manager how urgent is my task and why it should be done if needed. If its urgent enough and I can’t wait, communicate with team explaining what goals going to be achieved by implementing and why its important"See full answer

    Software Engineer
    Behavioral
  • +1

    "Approach 1: Use sorting and return the kth largest element from the sorted list. Time complexity: O(nlogn) Approach 2: Use max heap and then select the kth largest element. time complexity: O(n+logn) Approach 3: Quickselect. Time complexity O(n) I explained my interviewer the 3 approaches. He told me to solve in a naive manner. Used Approach 1 had some time left so coded approach 3 also The average time complexity of Quickselect is O(n), making it very efficient for its purpose. However, in"

    GalacticInterviewer - "Approach 1: Use sorting and return the kth largest element from the sorted list. Time complexity: O(nlogn) Approach 2: Use max heap and then select the kth largest element. time complexity: O(n+logn) Approach 3: Quickselect. Time complexity O(n) I explained my interviewer the 3 approaches. He told me to solve in a naive manner. Used Approach 1 had some time left so coded approach 3 also The average time complexity of Quickselect is O(n), making it very efficient for its purpose. However, in"See full answer

    Software Engineer
    Coding
    +1 more
  • Google logoAsked at Google 

    "def encode(root): if not root: return [] def dfs(node): if not node: return res.append(node.val) res.append(len(node,children)) for child_node in node.children: dfs(child_node) res = [] dfs(root) return res def decode(arr): if not arr: return None n = len(arr) i = 0 def dfs(val, children_count): if children_count == 0: return Node(val) cur_node = Node(val) cur_node.children = [] for j in range(children_count): nonlocal i i += 2 cur_node.children.append(dfs(arr[i], arr[i"

    Ying T. - "def encode(root): if not root: return [] def dfs(node): if not node: return res.append(node.val) res.append(len(node,children)) for child_node in node.children: dfs(child_node) res = [] dfs(root) return res def decode(arr): if not arr: return None n = len(arr) i = 0 def dfs(val, children_count): if children_count == 0: return Node(val) cur_node = Node(val) cur_node.children = [] for j in range(children_count): nonlocal i i += 2 cur_node.children.append(dfs(arr[i], arr[i"See full answer

    Software Engineer
    Coding
  • Amazon logoAsked at Amazon 
    +4

    "this assumes that the dependency among courses is in a growing order: 0 -> 1 -> 2 -> ... if not, then the code will not work"

    Gabriele G. - "this assumes that the dependency among courses is in a growing order: 0 -> 1 -> 2 -> ... if not, then the code will not work"See full answer

    Software Engineer
    Data Structures & Algorithms
    +4 more
  • Apple logoAsked at Apple 
    +15

    "function isValid(s) { const stack = []; for (let i=0; i < s.length; i++) { const char = s.charAt(i); if (['(', '{', '['].includes(char)) { stack.push(char); } else { const top = stack.pop(); if ((char === ')' && top !== '(') || (char === '}' && top !== '{') || (char === ']' && top !== '[')) { return false; } } } return stack.length === 0"

    Tiago R. - "function isValid(s) { const stack = []; for (let i=0; i < s.length; i++) { const char = s.charAt(i); if (['(', '{', '['].includes(char)) { stack.push(char); } else { const top = stack.pop(); if ((char === ')' && top !== '(') || (char === '}' && top !== '{') || (char === ']' && top !== '[')) { return false; } } } return stack.length === 0"See full answer

    Software Engineer
    Data Structures & Algorithms
    +4 more
  • Visa logoAsked at Visa 

    "There are couple of reasons for it - Kind of role : Its a product manager role loaded with analytical work, So working with data in stringent regulatory guideline make it more exciting and thrilling. Location & industry is like - Cherry on the cake, Bangalore weather and BFI is at its all time peak as people spending behavior is changing continuously, it will be interesting to see big giants like visa are managing it."

    Nidhi S. - "There are couple of reasons for it - Kind of role : Its a product manager role loaded with analytical work, So working with data in stringent regulatory guideline make it more exciting and thrilling. Location & industry is like - Cherry on the cake, Bangalore weather and BFI is at its all time peak as people spending behavior is changing continuously, it will be interesting to see big giants like visa are managing it."See full answer

    Software Engineer
    Behavioral
    +4 more
  • Google logoAsked at Google 
    +6

    "I would first call out the two types of Google Doodles that are published. First would be the static doodle which just shows a picture, and users can get more information on it by hovering on it or clicking on it. Second would be the dynamic google doodles which are either short videos or games through which users engage a bit more. My top 3 metrics that covers both would be: Click-through rate and post-click CTR - Although different metrics, I clubbed them since they fall under similar"

    Rahul R. - "I would first call out the two types of Google Doodles that are published. First would be the static doodle which just shows a picture, and users can get more information on it by hovering on it or clicking on it. Second would be the dynamic google doodles which are either short videos or games through which users engage a bit more. My top 3 metrics that covers both would be: Click-through rate and post-click CTR - Although different metrics, I clubbed them since they fall under similar"See full answer

    Software Engineer
    Analytical
    +1 more
  • Amazon logoAsked at Amazon 
    +1

    "delete"

    David P. - "delete"See full answer

    Software Engineer
    Behavioral
    +1 more
Showing 101-120 of 438