Software Engineer 2 Interview Questions

2,525 software engineer 2 interview questions shared by candidates

1. Given string s and integer k. Find max number of vowels in substring of size k. a,e,i,o,u s = "abciiidef", k = 3 Output: 3 ("iii") s = "aeiou", k = 2 Output: 2 s = "abhishek", k = 4 Output : 2 2. You have N bags of candy. The ith bag contains arr[i] pieces of candy. It takes you 1 minute to eat all of the pieces of candy in the bag , and as soon as you finish, the bag refills with x/2 pieces of candies. You have k minutes to eat as much candy as possible. How many pieces of candy can you eat? N = 5 k = 3 arr = [2, 1, 7, 4, 2] output = 14
avatar

SDE-2 Backend

Interviewed at Amazon

3.5
Dec 6, 2021

1. Given string s and integer k. Find max number of vowels in substring of size k. a,e,i,o,u s = "abciiidef", k = 3 Output: 3 ("iii") s = "aeiou", k = 2 Output: 2 s = "abhishek", k = 4 Output : 2 2. You have N bags of candy. The ith bag contains arr[i] pieces of candy. It takes you 1 minute to eat all of the pieces of candy in the bag , and as soon as you finish, the bag refills with x/2 pieces of candies. You have k minutes to eat as much candy as possible. How many pieces of candy can you eat? N = 5 k = 3 arr = [2, 1, 7, 4, 2] output = 14

System Design: Design a google doc-type service Coding Question: Leetcode-like questions that require you to solve problems mostly with hashmaps (think two-sum but with an object) Watch out for questions that are not looking for exact results but coding styles as if you don't expect them you can waste a lot of time making assumptions.
avatar

SDE-2

Interviewed at Amazon

3.5
May 23, 2024

System Design: Design a google doc-type service Coding Question: Leetcode-like questions that require you to solve problems mostly with hashmaps (think two-sum but with an object) Watch out for questions that are not looking for exact results but coding styles as if you don't expect them you can waste a lot of time making assumptions.

Viewing 1501 - 1510 interview questions

Glassdoor has 2,525 interview questions and reports from Software engineer 2 interviews. Prepare for your interview. Get hired. Love your job.