Sde Interview Questions

16,641 sde interview questions shared by candidates

There a tiles in a house arranged in a straight line, they are named -, F, D. Where - is an empty tile, F is a food tile, and D is a dirty tile. You need to find the minimum cost need to put all the food tiles together. You can only move a tile one step at a time, only at a clean tile, if the tile is dirty you have to clean it then move to it. You are given a string, example "--F-D--F--" and you're given x and y respectively, where x is the cost to move a food tile to an adjacent tile, and y is the cost of cleaning a dirty tile. You're also given "q" the number of queries. Your input looks like: n q - where n is the length of the given string, q is the number of queries s - the input string of tiles x y - these are the queries given q times, if q is 1 you'll only have one row of x and y, and so on
avatar

Software Development Engineer (SDE)

Interviewed at Meesho

4.1
Jul 28, 2025

There a tiles in a house arranged in a straight line, they are named -, F, D. Where - is an empty tile, F is a food tile, and D is a dirty tile. You need to find the minimum cost need to put all the food tiles together. You can only move a tile one step at a time, only at a clean tile, if the tile is dirty you have to clean it then move to it. You are given a string, example "--F-D--F--" and you're given x and y respectively, where x is the cost to move a food tile to an adjacent tile, and y is the cost of cleaning a dirty tile. You're also given "q" the number of queries. Your input looks like: n q - where n is the length of the given string, q is the number of queries s - the input string of tiles x y - these are the queries given q times, if q is 1 you'll only have one row of x and y, and so on

Viewing 1721 - 1730 interview questions

Glassdoor has 16,641 interview questions and reports from Sde interviews. Prepare for your interview. Get hired. Love your job.