From aea2c59576cefb46ed78e51a1d1c43fa7af81f14 Mon Sep 17 00:00:00 2001 From: Ricardo Amaral <120180055+ricardoitv@users.noreply.github.com> Date: Mon, 5 Jan 2026 13:56:24 +0000 Subject: [PATCH 1/6] README for fstree v3 with features to implement (#1) --- fstree/v3/readme.md | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 fstree/v3/readme.md diff --git a/fstree/v3/readme.md b/fstree/v3/readme.md new file mode 100644 index 0000000..4fce4f7 --- /dev/null +++ b/fstree/v3/readme.md @@ -0,0 +1,7 @@ +Like [v2](../v2/readme.md) but: +- Will aim to use a bounded worker pool/buffered channel semaphore pattern when traversing the tree of dirs +- Remove the use of `log.Fatal` +- Have `Run()` return errors +- Better separation of concerns +- Add metrics (Add a channel for “nodes processed” - can print progress) +- Support CLI args (like `--path /some/dir --output json --max-workers 10`) From 65f7c04cd8fb43f196df6a83029e09ef23c6fdc9 Mon Sep 17 00:00:00 2001 From: rcdmrl <37176450+rcdmrl@users.noreply.github.com> Date: Mon, 5 Jan 2026 13:57:04 +0000 Subject: [PATCH 2/6] Update README.md --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index 984d2df..1a22dea 100644 --- a/README.md +++ b/README.md @@ -16,3 +16,4 @@ Each package may contain multiple versions where I experiment with different app ## WIPs - [tui/v2](./tui/v2/readme.md) - [todoapp/v1](./todoapp/v1/readme.md) +- [fstree/v3](./fstree/v3/readme.md) From 1af29c82d2b33c5148953f8be6778d1da96ac0b0 Mon Sep 17 00:00:00 2001 From: rcdmrl <37176450+rcdmrl@users.noreply.github.com> Date: Mon, 5 Jan 2026 16:26:13 +0000 Subject: [PATCH 3/6] Add README for Coding Interviews project --- CodingInterviews/readme.md | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 CodingInterviews/readme.md diff --git a/CodingInterviews/readme.md b/CodingInterviews/readme.md new file mode 100644 index 0000000..15ba8c0 --- /dev/null +++ b/CodingInterviews/readme.md @@ -0,0 +1,3 @@ +# Coding Interviews + +Algorithms, data structures, Leetcode style problems and just coding-interview style katas. From 32c2d8da5d952db754216f27bed1b373b02647a7 Mon Sep 17 00:00:00 2001 From: rcdmrl <37176450+rcdmrl@users.noreply.github.com> Date: Mon, 5 Jan 2026 16:37:13 +0000 Subject: [PATCH 4/6] Enhance readme with data structure details Expanded the readme to include detailed descriptions of various data structures and their operations, such as Dynamic Array, Stack, Queue, and more. --- CodingInterviews/readme.md | 218 +++++++++++++++++++++++++++++++++++++ 1 file changed, 218 insertions(+) diff --git a/CodingInterviews/readme.md b/CodingInterviews/readme.md index 15ba8c0..5ac651e 100644 --- a/CodingInterviews/readme.md +++ b/CodingInterviews/readme.md @@ -1,3 +1,221 @@ # Coding Interviews Algorithms, data structures, Leetcode style problems and just coding-interview style katas. + + +## To Do + +### **1. Dynamic Array** + +```go +// Basic CRUD + utility operations +func (a *MyDynamicArray[T]) Add(val T) // append at end +func (a *MyDynamicArray[T]) Insert(index int, val T) // insert at specific index +func (a *MyDynamicArray[T]) Remove(index int) T // remove element at index +func (a *MyDynamicArray[T]) Get(index int) T +func (a *MyDynamicArray[T]) Set(index int, val T) +func (a *MyDynamicArray[T]) Size() int +func (a *MyDynamicArray[T]) Capacity() int +func (a *MyDynamicArray[T]) Clear() +func (a *MyDynamicArray[T]) Contains(val T) bool +func (a *MyDynamicArray[T]) IndexOf(val T) int +func (a *MyDynamicArray[T]) ToSlice() []T +``` + +--- + +### **2. Stack** + +```go +func (s *Stack[T]) Push(val T) +func (s *Stack[T]) Pop() T +func (s *Stack[T]) Peek() T +func (s *Stack[T]) IsEmpty() bool +func (s *Stack[T]) Size() int +func (s *Stack[T]) Clear() +``` + +--- + +### **3. Queue** + +```go +func (q *Queue[T]) Enqueue(val T) +func (q *Queue[T]) Dequeue() T +func (q *Queue[T]) Peek() T +func (q *Queue[T]) IsEmpty() bool +func (q *Queue[T]) Size() int +func (q *Queue[T]) Clear() +``` + +--- + +### **4. Deque (Double-Ended Queue)** + +```go +func (d *Deque[T]) AddFront(val T) +func (d *Deque[T]) AddBack(val T) +func (d *Deque[T]) RemoveFront() T +func (d *Deque[T]) RemoveBack() T +func (d *Deque[T]) PeekFront() T +func (d *Deque[T]) PeekBack() T +func (d *Deque[T]) IsEmpty() bool +func (d *Deque[T]) Size() int +func (d *Deque[T]) Clear() +``` + +--- + +### **5. Linked List (Singly / Doubly)** + +```go +func (l *LinkedList[T]) AddFront(val T) +func (l *LinkedList[T]) AddBack(val T) +func (l *LinkedList[T]) InsertAt(index int, val T) +func (l *LinkedList[T]) RemoveAt(index int) T +func (l *LinkedList[T]) RemoveVal(val T) bool +func (l *LinkedList[T]) Get(index int) T +func (l *LinkedList[T]) Set(index int, val T) +func (l *LinkedList[T]) Size() int +func (l *LinkedList[T]) IsEmpty() bool +func (l *LinkedList[T]) Contains(val T) bool +func (l *LinkedList[T]) ToSlice() []T +``` + +--- + +### **6. Hash Map** + +```go +func (m *HashMap[K, V]) Put(key K, val V) +func (m *HashMap[K, V]) Get(key K) (V, bool) +func (m *HashMap[K, V]) Remove(key K) +func (m *HashMap[K, V]) ContainsKey(key K) bool +func (m *HashMap[K, V]) Keys() []K +func (m *HashMap[K, V]) Values() []V +func (m *HashMap[K, V]) Size() int +func (m *HashMap[K, V]) Clear() +``` + +--- + +### **7. Set** + +```go +func (s *Set[T]) Add(val T) +func (s *Set[T]) Remove(val T) +func (s *Set[T]) Contains(val T) bool +func (s *Set[T]) Size() int +func (s *Set[T]) Clear() +func (s *Set[T]) Union(other *Set[T]) *Set[T] +func (s *Set[T]) Intersection(other *Set[T]) *Set[T] +func (s *Set[T]) Difference(other *Set[T]) *Set[T] +``` + +--- + +### **8. Binary Tree** + +```go +func (t *BinaryTree[T]) Insert(val T) +func (t *BinaryTree[T]) Delete(val T) +func (t *BinaryTree[T]) Find(val T) *TreeNode[T] +func (t *BinaryTree[T]) Inorder() []T +func (t *BinaryTree[T]) Preorder() []T +func (t *BinaryTree[T]) Postorder() []T +func (t *BinaryTree[T]) Size() int +func (t *BinaryTree[T]) Height() int +func (t *BinaryTree[T]) Clear() +``` + +--- + +### **9. Binary Search Tree (BST)** + +```go +func (bst *BST[T]) Insert(val T) +func (bst *BST[T]) Delete(val T) +func (bst *BST[T]) Find(val T) *TreeNode[T] +func (bst *BST[T]) Min() T +func (bst *BST[T]) Max() T +func (bst *BST[T]) Inorder() []T +func (bst *BST[T]) Predecessor(val T) *TreeNode[T] +func (bst *BST[T]) Successor(val T) *TreeNode[T] +func (bst *BST[T]) Size() int +func (bst *BST[T]) Height() int +func (bst *BST[T]) Clear() +``` + +--- + +### **10. Heap (Min / Max)** + +```go +func (h *Heap[T]) Insert(val T) +func (h *Heap[T]) Extract() T // Min or Max +func (h *Heap[T]) Peek() T +func (h *Heap[T]) Size() int +func (h *Heap[T]) Clear() +func (h *Heap[T]) Heapify() // Optional: build heap from slice +``` + +--- + +### **11. Graph (Adjacency List)** + +```go +func (g *Graph[T]) AddVertex(v T) +func (g *Graph[T]) RemoveVertex(v T) +func (g *Graph[T]) AddEdge(u, v T) +func (g *Graph[T]) RemoveEdge(u, v T) +func (g *Graph[T]) Neighbors(v T) []T +func (g *Graph[T]) BFS(start T) []T +func (g *Graph[T]) DFS(start T) []T +func (g *Graph[T]) HasPath(u, v T) bool +func (g *Graph[T]) Clear() +``` + +--- + +### **12. Trie** + +```go +func (t *Trie) Insert(word string) +func (t *Trie) Search(word string) bool +func (t *Trie) StartsWith(prefix string) bool +func (t *Trie) Delete(word string) bool +func (t *Trie) Clear() +``` + +--- + +### **13. Priority Queue** + +```go +func (pq *PriorityQueue[T]) Insert(val T, priority int) +func (pq *PriorityQueue[T]) Extract() (T, int) // returns val + priority +func (pq *PriorityQueue[T]) Peek() (T, int) +func (pq *PriorityQueue[T]) Size() int +func (pq *PriorityQueue[T]) Clear() +``` + +--- + + +### **14. Array / Slice Operations** + +```go +func MaxSlidingWindow(nums []int, k int) []int +func MinSlidingWindow(nums []int, k int) []int +func PrefixSum(nums []int) []int +func BinarySearch(nums []int, target int) int +func Kadane(nums []int) int // Max contiguous sum +func Reverse(nums []int) +func Rotate(nums []int, k int) +func Partition(nums []int, pivot int) +func MergeIntervals(intervals [][]int) [][]int +func Subarrays(nums []int) [][]int +func TwoPointersSum(nums []int, target int) (int,int) +func CountFrequency(nums []int) map[int]int +``` + From d4634144dd612e742ee538f0e2a882a5a0c0aeee Mon Sep 17 00:00:00 2001 From: rcdmrl <37176450+rcdmrl@users.noreply.github.com> Date: Mon, 5 Jan 2026 17:51:42 +0000 Subject: [PATCH 5/6] Add 'Ideas for later' section to README Added a section for future ideas with a link to an OAuth 2.0 course. --- README.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/README.md b/README.md index 1a22dea..ad9e24b 100644 --- a/README.md +++ b/README.md @@ -17,3 +17,8 @@ Each package may contain multiple versions where I experiment with different app - [tui/v2](./tui/v2/readme.md) - [todoapp/v1](./todoapp/v1/readme.md) - [fstree/v3](./fstree/v3/readme.md) + + +## Ideas for later + +- [OAuth 2.0 Course for Beginners @ freeCodeCamp](https://www.youtube.com/watch?v=WSsOXo07LeE) From 2579e0afab53852ba9839ca0bd642982cb3a4c4b Mon Sep 17 00:00:00 2001 From: rcdmrl <37176450+rcdmrl@users.noreply.github.com> Date: Mon, 5 Jan 2026 17:52:16 +0000 Subject: [PATCH 6/6] Add note to use GO in OAuth 2.0 course --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index ad9e24b..2b43bf2 100644 --- a/README.md +++ b/README.md @@ -22,3 +22,4 @@ Each package may contain multiple versions where I experiment with different app ## Ideas for later - [OAuth 2.0 Course for Beginners @ freeCodeCamp](https://www.youtube.com/watch?v=WSsOXo07LeE) + - Follow along but use GO wherever possible