Updated source --> Added bets, cleaned code