Skip to content

Commit

Permalink
🎉 Make combine and mess function for combinate word
Browse files Browse the repository at this point in the history
  • Loading branch information
julioliraup committed Mar 28, 2020
1 parent 77b9b94 commit b806899
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,22 @@ func inverter(word string) string {
}
return string(runes)
}
func mess(word string, all_list []string) []string {
list := []string {}
for _, i := range all_list {
list = append(list, word + i)
}
return list
}
func combine(all_list []string) []string {
final_words := []string {}

for _, i := range all_list {
final_words = append(final_words, mess(i, all_list)...)
}

return final_words
}

func main() {
final_content := []string {}
Expand All @@ -89,6 +105,8 @@ func main() {

// Running functions for make wordlist
for _, word := range content {
final_content = content
final_content = append(final_content, combine(content)...)
final_content = append(final_content, leet(word))
final_content = append(final_content, count1(word))
final_content = append(final_content, count2(word))
Expand Down

0 comments on commit b806899

Please sign in to comment.