摇骰子游戏升级 此次更改增加下注功能,启动资金1000元,每次赔率都是一倍,钱输光退出. 源码: #!/user/bin/env python #-*-coding:utf-8 -*- #Author: qinjiaxi import random #一次摇三个骰子并将结果存在列表中 def role_a_dice(number = 3, point = None ): print('Let\'s play a game') if point is None: point = [] while…
<script type="text/javascript"> //--身份证号码验证-支持新的带x身份证 function isIdCardNo(num) { var factorArr = new Array(7,9,10,5,8,4,2,1,6,3,7,9,10,5,8,4,2,1); var error; var varArray = new Array(); var intValue; var lngProduct = 0; var intCheckDigit;…
/* 1.是否以某字符串结尾 endsWith(theStr,endStr) @param theStr:要判断的字符串 @param endStr:以此字符串结尾 @return boolean; */ function endsWith(theStr,endStr) { var theStrLength=theStr.length; var endStrLength=endStr.length; var theStrEnd=theStr.substring(theStrLength-endS…