Skip to content

Commit 5390d9c

Browse files
add 2798
1 parent 4caaac2 commit 5390d9c

File tree

2 files changed

+12
-0
lines changed
  • paginated_contents/algorithms/3rd_thousand
  • src/main/java/com/fishercoder/solutions/thirdthousand

2 files changed

+12
-0
lines changed

Diff for: paginated_contents/algorithms/3rd_thousand/README.md

+1
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
| 2815 | [Max Pair Sum in an Array](https://leetcode.com/problems/max-pair-sum-in-an-array/) | [Java](https://github.com/fishercoder1534/Leetcode/blob/master/src/main/java/com/fishercoder/solutions/thirdthousand/_2815.java) | | Easy |
1212
| 2812 | [Find the Safest Path in a Grid](https://leetcode.com/problems/find-the-safest-path-in-a-grid/) | [Java](https://github.com/fishercoder1534/Leetcode/blob/master/src/main/java/com/fishercoder/solutions/thirdthousand/_2812.java) | | Medium |BFS
1313
| 2810 | [Faulty Keyboard](https://leetcode.com/problems/faulty-keyboard/) | [Java](https://github.com/fishercoder1534/Leetcode/blob/master/src/main/java/com/fishercoder/solutions/thirdthousand/_2810.java) | | Easy |
14+
| 2798 | [Number of Employees Who Met the Target](https://leetcode.com/problems/number-of-employees-who-met-the-target/) | [Java](https://github.com/fishercoder1534/Leetcode/blob/master/src/main/java/com/fishercoder/solutions/thirdthousand/_2798.java) | | Easy |
1415
| 2788 | [Split Strings by Separator](https://leetcode.com/problems/split-strings-by-separator/) | [Java](https://github.com/fishercoder1534/Leetcode/blob/master/src/main/java/com/fishercoder/solutions/thirdthousand/_2788.java) | | Easy |
1516
| 2784 | [Check if Array is Good](https://leetcode.com/problems/check-if-array-is-good/) | [Java](https://github.com/fishercoder1534/Leetcode/blob/master/src/main/java/com/fishercoder/solutions/thirdthousand/_2784.java) | | Easy |
1617
| 2778 | [Sum of Squares of Special Elements](https://leetcode.com/problems/sum-of-squares-of-special-elements/) | [Java](https://github.com/fishercoder1534/Leetcode/blob/master/src/main/java/com/fishercoder/solutions/thirdthousand/_2778.java) | | Easy |
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
package com.fishercoder.solutions.thirdthousand;
2+
3+
import java.util.Arrays;
4+
5+
public class _2798 {
6+
public static class Solution1 {
7+
public int numberOfEmployeesWhoMetTarget(int[] hours, int target) {
8+
return (int) Arrays.stream(hours).filter(hour -> hour >= target).count();
9+
}
10+
}
11+
}

0 commit comments

Comments
 (0)