Skip to content

gte() function

첫 번째 인자가 두 번째 인자보다 크거나 같으면 true를 반환하고, 그렇지 않으면 false를 반환합니다.

Signature:

typescript
declare function gte(a: string): (b: string) => boolean;

Example

ts
gte(5, 1); // expected true
gte(1, 1); // expected true
gte(1, 5); // expected false
gte("a", "b"); // expected false
gte("b", "a"); // expected true

filter(gte(5), [1, 2, 4, 5, 8, 9]); // Iterable<[1, 2, 4, 5]>
filter(gte(1), [2, 3, 4]); // Iterable<[]>
filter(gte("b"), ["a", "b", "c"]); // Iterable<["a", "b"]>
filter(gte("a"), ["b"]); // Itreable<[]>

Open Source Code

Released under the Apache-2.0 License.