public static void assignTeams() 
	{		
		Random rand = new Random();
		int random, p = players.length, bigTeam = 0;
		
		for (int i = 0; i < p; i++) 
		{			
			random = rand.nextInt(teams.length);
			if(teams[random].getPlayers().size() < (p / teams.length))	//balance out teams
			{
				teams[random].register(players[i]);
				players[i].setTeamNum(random);
			}
			else if((teams[random].getPlayers().size() < ((p / teams.length) + 1 )) && bigTeam < (p % teams.length))	//balance out teams when odd number of players
			{
				bigTeam++;
				teams[random].register(players[i]);
				players[i].setTeamNum(random);
			}
			else
			{
				i--;	//if player was not assigned to a team
			}
		}
	}