LeetCode 115: two solutions - Space optimization using a 1D array
See how a simple 1D array optimization reduces space complexity from O(n * m) to O(m) while keeping O(n * m) time complexity.
Read moreSee how a simple 1D array optimization reduces space complexity from O(n * m) to O(m) while keeping O(n * m) time complexity.
Read moreWe're used to evaluating an algorithm's Time complexity, but we often overlook its Space complexity. However, often the best solution for Time complexity is a brute-force solution for Space complexity and vice versa.
Read moreWe're used to evaluating an algorithm's Time complexity, but we often overlook its Space complexity. However, often the best solution for Time complexity is a brute-force solution for Space complexity and vice versa.
Read more