def get_team_avg_height(team):
    """calculate a new avg_height based on current team's player's heights.
    If no players on team, return 0
    """
    num_players = len(team['players'])
    if num_players == 0:
        # No players return 0
        return 0
    # calculate average height of existing players
    total_height = 0
    for player in team['players']:
        total_height += int(player['Height (inches)'])
    return total_height / num_players