Skip to content

Commit 25063f2

Browse files
committed
#74: description update
1 parent aa0b4d3 commit 25063f2

File tree

1 file changed

+16
-3
lines changed

1 file changed

+16
-3
lines changed

c-sharp/Problems/binary-search/SearchA2DMatrix.cs

Lines changed: 16 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,25 @@
33
* Search a 2D Matrix
44
**
55
* You are given an m x n integer matrix matrix with the following two properties:
6-
* Each row is sorted in non-decreasing order.
7-
* The first integer of each row is greater than the last integer of the previous row.
6+
* Each row is sorted in non-decreasing order.
7+
* The first integer of each row is greater than the last integer of the previous row.
88
*
99
* Given an integer target, return true if target is in matrix or false otherwise.
10-
*
1110
* You must write a solution in O(log(m * n)) time complexity.
11+
*
12+
* Example 1:
13+
* Input: matrix = [[1,3,5,7],[10,11,16,20],[23,30,34,60]], target = 3
14+
* Output: true
15+
*
16+
* Example 2:
17+
* Input: matrix = [[1,3,5,7],[10,11,16,20],[23,30,34,60]], target = 13
18+
* Output: false
19+
*
20+
* Constraints:
21+
* • m == matrix.length
22+
* • n == matrix[i].length
23+
* • 1 <= m, n <= 100
24+
* • -10^4 <= matrix[i][j], target <= 10^4
1225
**
1326
* https://leetcode.com/problems/search-a-2d-matrix/
1427
***/

0 commit comments

Comments
 (0)