Skip to content

Rm/fix lint problems #39

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Apr 5, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ This learning platform offers several advantages over traditional learning metho
* Time and Space Analysis
* Data Structures
* [Arrays](./array)
* [Strings](./string)
* [Strings](./strings)
* [Linked Lists](./linkedlist)
* [Stacks](./stack)
* [Queues](./queue)
Expand Down
2 changes: 1 addition & 1 deletion array/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ Both addition and deletion operations on arrays can be O(n) operations in Arrays

## Application

Arrays are used wherever sequential data or more than one piece of data is needed. The fast read and write access to a given element makes arrays suitable for implementing other data structures such as [strings](../string), [stacks](../stack), [queues](../queue) and [hash tables](../hashtable).
Arrays are used wherever sequential data or more than one piece of data is needed. The fast read and write access to a given element makes arrays suitable for implementing other data structures such as [strings](../strings), [stacks](../stack), [queues](../queue) and [hash tables](../hashtable).

## Rehearsal

Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package string
package strings

import (
"strings"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package string
package strings

import (
"strings"
Expand All @@ -13,8 +13,8 @@ func TestInMemoryDictionary(t *testing.T) {
{"EXISTS A\nSET A 1\nGET A\nEXISTS A\nUNSET A\nGET A\nEXISTS A", "false 1 true nil false"},
{"GET A\nBEGIN\nSET A 1\nGET A\nROLLBACK\nGET A", "nil 1 nil"},
{"GET A\nBEGIN\nSET A 1\nGET A\nCOMMIT\nGET A", "nil 1 1"},
{"SET A 1\nGET A\nBEGIN\nSET A 2\nGET A\nBEGIN\nUNSET A\nGET A\nCOMMIT\nROLLBACK\nGET A", "1 2 nil 1"},
{"SET A 2\nGET A\nBEGIN\nSET A 1\nGET A\nCOMMIT\nGET A\nBEGIN\nSET A 2\nGET A\nROLLBACK\nGET A", "2 1 1 2 1"},
{"SET A 1\nGET A\nBEGIN\nSET A 2\nGET A\nBEGIN\nUNSET A\nGET A\nCOMMIT\nGET A\nROLLBACK\nGET A", "1 2 nil nil 1"},
}

for i, test := range tests {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package string
package strings

// LongestDictionaryWordContainingKey returns the longest word in a dictionary
// containing every letter of a key
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package string
package strings

import (
"testing"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package string
package strings

// LongestSubstringOfTwoChars returns the longest substring of two different characters in a string
func LongestSubstringOfTwoChars(input string) string {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package string
package strings

import (
"testing"
Expand Down
2 changes: 1 addition & 1 deletion string/look_and_tell.go → strings/look_and_tell.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package string
package strings

import (
"strconv"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package string
package strings

import (
"testing"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package string
package strings

import (
"strings"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package string
package strings

import (
"testing"
Expand Down
2 changes: 1 addition & 1 deletion string/reverse_vowels.go → strings/reverse_vowels.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package string
package strings

import "errors"

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package string
package strings

import (
"testing"
Expand Down