Angad Sandhu
Search
Browse

73_Set_Matrix_Zeroes

Source name
73_Set_Matrix_Zeroes.py
# File: Leetcode/Solutions/73_Set_Matrix_Zeroes.py

"""
Problem Number: 73
Problem Name: Set Matrix Zeroes
Difficulty: Medium
Tags: Matrix, In-place, Neetcode 150
Company (Frequency): Amazon, Google, Facebook, Microsoft, Apple
Leetcode Link: <https://leetcode.com/problems/set-matrix-zeroes/description/>

DESCRIPTION

If an element is 0, set its entire row and column to 0. Do it in-place with O(1) extra space.
Approaches:

* Use first row and first column as markers; handle those rows specially.
"""

Browse the library