Skip to content

Commit

Permalink
Alphabetize function order
Browse files Browse the repository at this point in the history
  • Loading branch information
Henry-Sarabia committed Feb 15, 2019
1 parent cae9b60 commit efc81df
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions sliceconv.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,6 @@ import (
"strconv"
)

// Itoa converts the provided integers into their respective string representations
// in base 10.
func Itoa(ints ...int) []string {
var str []string
for _, i := range ints {
str = append(str, strconv.Itoa(i))
}
return str
}

// Atoi converts the provided strings into their respective base 10 integer
// representations. If any of the strings are not valid digits, an error is returned.
func Atoi(str ...string) ([]int, error) {
Expand All @@ -30,3 +20,13 @@ func Atoi(str ...string) ([]int, error) {

return ints, nil
}

// Itoa converts the provided integers into their respective string representations
// in base 10.
func Itoa(ints ...int) []string {
var str []string
for _, i := range ints {
str = append(str, strconv.Itoa(i))
}
return str
}

0 comments on commit efc81df

Please sign in to comment.