Back to problems

Minesweeper Board Generation

Algorithm · Block · Easy

Minesweeper Board Generation Easy · Topics · Company Tags · Hints Write a function, generate_minesweeper_board(col, row, number_of_mines), that creates a rectangular game board for Minesweeper. The board should have col columns and row rows. Exactly number_of_mines cells must contain a mine, shown as the character ''. All remaining cells should be shown as '_'. The board can be returned as a multi-line string, with each row on its own line, or as a list of strings. The…

Checking your access…