Software Engineers Interview Questions

420,318 software engineers interview questions shared by candidates

Implement a class called AirMap that has two methods: 1. add_route(start, destination) - adds ONE WAY connecting flight from one airport to another 2. print_all_routes(start, destination) - prints all possible routes from start to destination Given the following routes, print all possible routes between the airport C and D: A -----> B B -----> A A -----> C C -----> A A -----> D D -----> A B -----> C C -----> B B -----> D D -----> B Expected Output: C,A,B,D C,A,D C,B,A,D C,B,D
avatar

Senior Software Engineer

Interviewed at Bloomberg

4
Nov 1, 2021

Implement a class called AirMap that has two methods: 1. add_route(start, destination) - adds ONE WAY connecting flight from one airport to another 2. print_all_routes(start, destination) - prints all possible routes from start to destination Given the following routes, print all possible routes between the airport C and D: A -----> B B -----> A A -----> C C -----> A A -----> D D -----> A B -----> C C -----> B B -----> D D -----> B Expected Output: C,A,B,D C,A,D C,B,A,D C,B,D

Dynamic programming question. Given a list of non-overlapping (but intersecting) intervals {[0-2], [2-5], [6-10]} find the largest non-intersecting set with mamimum range. I.e in above | {[2-5], [6-10]} | > | {[0-2], [6-10]} |
avatar

Software Engineer

Interviewed at Nutanix

3.8
Apr 29, 2018

Dynamic programming question. Given a list of non-overlapping (but intersecting) intervals {[0-2], [2-5], [6-10]} find the largest non-intersecting set with mamimum range. I.e in above | {[2-5], [6-10]} | > | {[0-2], [6-10]} |

Write a function that: given a 1 row 2^n column matrix containing integers 1 to 2^n, divide the matrix in two, and place the right half of the matrix below the left half. Repeat this process until the matrix is 2^n rows and 1 column and return the result.
avatar

Associate Software Engineer

Interviewed at MathWorks

4.3
Sep 3, 2016

Write a function that: given a 1 row 2^n column matrix containing integers 1 to 2^n, divide the matrix in two, and place the right half of the matrix below the left half. Repeat this process until the matrix is 2^n rows and 1 column and return the result.

Viewing 1651 - 1660 interview questions

Glassdoor has 420,318 interview questions and reports from Software engineers interviews. Prepare for your interview. Get hired. Love your job.