Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- for(var n=0;n<1000;n++){
- total=0;
- for (var i=0;i<1000;i++){
- //bet is taken
- total -=lbet + greenBet;
- s = spin();
- winq = win(s);
- //if won recive winnings
- total += 2*lbet*winq;
- //recive insurance winnings
- total +=greenBet*s*36==0;
- lbet = betV(lbet,winq);
- if(lbet%64==0){
- greenBet=lbet/64;
- }else{
- greenBet=0;
- }
- //console.log(total);
- }
- data[n]=total;
- }
- function betV(lbet,lw){return Math.min(lbet*2*!lw + lw,Math.pow(2,20));}
Advertisement
Add Comment
Please, Sign In to add comment