Skip to content

Commit

Permalink
chore: prettier code
Browse files Browse the repository at this point in the history
  • Loading branch information
rulanugrh committed Mar 11, 2024
1 parent 549d6e6 commit e2d25d3
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions algorithm/algorithm_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ import (
)

func TestCompressLZW(t *testing.T) {
str := CompressLZW("Australia")
expected := []int{65, 117, 115, 116, 114, 97, 108, 105, 97}
str := CompressLZW("Australia")
expected := []int{65, 117, 115, 116, 114, 97, 108, 105, 97}

assert.Equal(t, expected, str)
assert.Equal(t, expected, str)
}
2 changes: 1 addition & 1 deletion algorithm/lzw-compression.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ package algorithm

func CompressLZW(str string) []int {
code := 256
dict := make(map[string]int)
dict := make(map[string]int)
for i := 0; i < 256; i++ {
dict[string(rune(i))] = i
}
Expand Down

0 comments on commit e2d25d3

Please sign in to comment.