Senior Frontend Engineer Interview Questions

1,542 senior frontend engineer interview questions shared by candidates

Use React to make a 4x4 grid where each cell can have a normal, active, or dead state (should be reflected with colors). Clicking a cell will toggle it between normal and active, and activating a normal cell while another cell is active will make those two cells "fight" (use random number) and return one to normal and the other to dead. At the end, output the winning cell and all the cells that that cell defeated. Follow up: "What would you change about the code if you were going to add more functionality to the cells later"
avatar

Senior Frontend Engineer

Interviewed at Ramp

3.9
Jul 26, 2022

Use React to make a 4x4 grid where each cell can have a normal, active, or dead state (should be reflected with colors). Clicking a cell will toggle it between normal and active, and activating a normal cell while another cell is active will make those two cells "fight" (use random number) and return one to normal and the other to dead. At the end, output the winning cell and all the cells that that cell defeated. Follow up: "What would you change about the code if you were going to add more functionality to the cells later"

Viewing 1081 - 1090 interview questions

Glassdoor has 1,542 interview questions and reports from Senior frontend engineer interviews. Prepare for your interview. Get hired. Love your job.