package main // All Battle Logic is in here func Battle(army1, army2 []Army) { allCombatants = append(army1, army2...) sort.Sort(ByPower(allCombatants)) for _, v := range allCombatants { fmt.Print("%d %d %d (%d)\n", v.tp, v.units, v.hp, v.Power()) } }