2023-03-23 13:53:46 +01:00
|
|
|
package cmd
|
|
|
|
|
|
|
|
func reverse(elements []string) []string {
|
2023-03-25 15:16:26 +01:00
|
|
|
for i := 0; i < len(elements)/2; i++ {
|
|
|
|
j := len(elements) - i - 1
|
|
|
|
elements[i], elements[j] = elements[j], elements[i]
|
|
|
|
}
|
|
|
|
return elements
|
2023-03-23 13:53:46 +01:00
|
|
|
}
|