gt

源码

https://github.com/ddzy/ts-utility-plugins/tree/master/src/ddzy/utility/others/gt

说明

检查x是否大于y

用法

gt.ts
gt.test.ts
import { gt } from "./ddzy/utility/others/gt";
// ? true
const s1 = [10, 5];
const p1 = gt(s1[0], s1[1]);
console.log(p1);
console.log('-----------------');
// ? false
const s2 = [10, 10];
const p2 = gt(s2[0], s2[1]);
console.log(p2);
console.log('----------------------');
// ? false
const s3 = [10, 20];
const p3 = gt(s3[0], s3[1]);
console.log(p3);
console.log('-----------------------');