Thanks everyone for the comments
Edit: Online version is up.
Click here to visit it!
Actually many gamblers have tried this strategy, they know it and will never win over the house. Many ppl probably don't bother to try it or don't know how to start. Why not build a web page for us to try it if you have your own website? So it will not be costy for you.
Looks like you're right. I'm going to build a basic web page so people can try without downloading
This is the exact reason I think why the simulator could be useful. There are some firm believers of martingale out there, thinking that it is impossible to have a long losing streak. With such a simulator, they could see the truth themselves before deciding to gamble their money away.
That's the exact reason why I built this simulator. I wanted to see what would happen if I ran martingale with 1 satoshi base bet (and around 0.05 BTC of starting balance). Well, I would lose everything sooner or later
For those thinking "this simulator is a trick and will only induce people to use martingale", you're wrong. This simulator is to see that they can lose their money quite easily. I wanted to see that with my own eyes as well, hence the simulator was built.
Whatever is written after this line is only meant to developers.
I will fork the script from the Gh account later but look at this :
while($betsTaken < $bets)
{
$betsTaken++;
/*Why to increment the bets taken ? Shouldn't it be $betsTaken+=$bets ?
$balance_ = bcsub($balance, $currentBet); // Take bet amount from balance
/*Mind making the statement recursive?
if($balance_ < 0)
{
break; // No more money to bet, abort
}
Why to increment the bets taken ? Shouldn't it be $betsTaken+=$bets ?
$betsTaken is increased after each bet. $betsTaken++ increases the variable $betsTaken by 1. It shouldn't be $betsTaken+=$bets, with your logic you would get something like this:
1
2
4
8
16
32
64
Instead of:
1
2
3
4
5
6
$betsTaken is not the bet amount. It's just a variable that stores how many bets we had so far.
Mind making the statement recursive?
I'm not quite understanding what you mean. The following line will stop the simulation:
break; // No more money to bet, abort