We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a3ec29f commit edfcccbCopy full SHA for edfcccb
src/main/kotlin/g3301_3400/s3395_subsequences_with_a_unique_middle_mode_i/Solution.kt
@@ -53,10 +53,14 @@ class Solution {
53
ans -= c2[leftY] * rightX * (right - rightX)
54
ans -= c2[rightY] * leftX * (left - leftX)
55
ans -=
56
- (leftY
+ (
57
+ leftY
58
* rightY
- * (leftX * (right - rightX - rightY)
59
- + rightX * (left - leftX - leftY))).toLong()
+ * (
60
+ leftX * (right - rightX - rightY) +
61
+ rightX * (left - leftX - leftY)
62
+ )
63
+ ).toLong()
64
}
65
66
leftCount[x]++
0 commit comments