This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function gcd(a,b){ | |
var minNum = Math.min(a,b),maxNum = Math.max(a,b),i=minNum,vper=0; | |
if(a ===0 || b===0) return maxNum; | |
for(var i=1;i<=maxNum;i++){ | |
vper = minNum * i; | |
if(vper % maxNum === 0){ | |
return vper; | |
break; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"Pacific/Niue": "(GMT-11:00) Niue", | |
"Pacific/Pago_Pago": "(GMT-11:00) Pago Pago", | |
"Pacific/Honolulu": "(GMT-10:00) Hawaii Time", | |
"Pacific/Rarotonga": "(GMT-10:00) Rarotonga", | |
"Pacific/Tahiti": "(GMT-10:00) Tahiti", | |
"Pacific/Marquesas": "(GMT-09:30) Marquesas", | |
"America/Anchorage": "(GMT-09:00) Alaska Time", | |
"Pacific/Gambier": "(GMT-09:00) Gambier", | |
"America/Los_Angeles": "(GMT-08:00) Pacific Time", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* MouseEvent path property polyfill | |
*/ | |
export function MouseEventPathPolyfill() { | |
if (!('path' in Event.prototype)) { | |
Object.defineProperty(Event.prototype, 'path', { | |
get: function () { | |
const path = []; | |
let currentElem = this.target; | |
while (currentElem) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ | |
/* | |
根据〖中华人民共和国国家标准 GB 11643-1999〗中有关公民身份号码的规定,公民身份号码是特征组合码,由十七位数字本体码和一位数字校验 | |
码组成。排列顺序从左至右依次为:六位数字地址码,八位数字出生日期码,三位数字顺序码和一位数字校验码。 | |
- 地址码表示编码对象常住户口所在县(市、旗、区)的行政区划代码。 | |
- 出生日期码表示编码对象出生的年、月、日,其中年份用四位数字表示,年、月、日之间不用分隔符。 | |
- 顺序码表示同一地址码所标识的区域范围内,对同年、月、日出生的人员编定的顺序号。顺序码的奇数分给男性,偶数分给女性。 | |
- 校验码是根据前面十七位数字码,按照ISO 7064:1983.MOD 11-2校验码计算出来的检验码。 | |
出生日期计算方法。 | |
- 15位的身份证编码首先把出生年扩展为4位,简单的就是增加一个19或18,这样就包含了所有1800-1999年出生的人; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div id="app"> | |
<div class="photo-wall"> | |
<div v-for="num in pageArr" v-html="num" class="brick"></div> | |
</div> | |
<v-page :setting="pagePhoto" @page-change="pagePhotoChange"></v-page> | |
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* u.random.js | |
* Random utils | |
*/ | |
var uRandom = uRandom = uRandom || {}; | |
/** | |
* Random integer value | |
* @param {Object} min | |
* @param {Object} max |