Skip to content

feat: add cs solution to lc problem: No.1887 #1984

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Nov 19, 2023
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Update README_EN.md to lc problem: No.1887
  • Loading branch information
dev-mauli authored Nov 19, 2023
commit 6d43c58f83127d963024544426eb45ad4ad9b507
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,24 @@ func reductionOperations(nums []int) int {
}
```

### **C#**

```cs
public class Solution {
public int ReductionOperations(int[] nums) {
Array.Sort(nums);
int ans = 0, up = 0;
for (int i = 1; i < nums.Length; i++) {
if (nums[i] != nums[i - 1]) {
up++;
}
ans += up;
}
return ans;
}
}
```

### **...**

```
Expand Down