@@ -15,13 +15,13 @@ void testLargestRectangleHistogramWithTypicalCases() {
15
15
assertEquals (expected , result );
16
16
17
17
// Another typical case with increasing heights
18
- heights = new int []{2 , 4 };
18
+ heights = new int [] {2 , 4 };
19
19
expected = "4" ;
20
20
result = LargestRectangle .largestRectanglehistogram (heights );
21
21
assertEquals (expected , result );
22
22
23
23
// Case with multiple bars of the same height
24
- heights = new int []{4 , 4 , 4 , 4 };
24
+ heights = new int [] {4 , 4 , 4 , 4 };
25
25
expected = "16" ;
26
26
result = LargestRectangle .largestRectanglehistogram (heights );
27
27
assertEquals (expected , result );
@@ -36,13 +36,13 @@ void testLargestRectangleHistogramWithEdgeCases() {
36
36
assertEquals (expected , result );
37
37
38
38
// Edge case with a single bar
39
- heights = new int []{5 };
39
+ heights = new int [] {5 };
40
40
expected = "5" ;
41
41
result = LargestRectangle .largestRectanglehistogram (heights );
42
42
assertEquals (expected , result );
43
43
44
44
// Edge case with all bars of height 0
45
- heights = new int []{0 , 0 , 0 };
45
+ heights = new int [] {0 , 0 , 0 };
46
46
expected = "0" ;
47
47
result = LargestRectangle .largestRectanglehistogram (heights );
48
48
assertEquals (expected , result );
@@ -69,7 +69,7 @@ void testLargestRectangleHistogramWithComplexCases() {
69
69
assertEquals (expected , result );
70
70
71
71
// Case with a peak in the middle
72
- heights = new int []{2 , 1 , 5 , 6 , 2 , 3 , 1 };
72
+ heights = new int [] {2 , 1 , 5 , 6 , 2 , 3 , 1 };
73
73
expected = "10" ;
74
74
result = LargestRectangle .largestRectanglehistogram (heights );
75
75
assertEquals (expected , result );
0 commit comments