BlackRockOtherSpring WeekQuestion #70

Write a program to determine if the current configuration of a Tic Tac Toe board allows the 'X' player to win on their next move. A winning configuration is one where three 'X's appear in a row. Your task is to find if there is a row, column, or diagonal with exactly two 'X's and an empty spot, indicating that 'X' can win by playing in that spot. The program should output the coordinate (x, y) of the winning location.

Unlock the Full Solution

Enter your email to get the detailed step-by-step solution to this BlackRock interview question, plus access to free interview prep resources.

We'll also send you a free HFT mock interview video.

Get All 104+ BlackRock Questions with Solutions

Plus 16+ hours of video lectures, resume tailoring, and 1:1 mentorship from quants.

Schedule a Call