Arsh's Newsletter

Subscribe
Archives
January 13, 2025

“Be curious, not judgmental.” - Ted Lasso

Hey hey!

First of all, I want to welcome and thank all the new folks who subscribed to the newsletter over the last couple of days. I really appreciate the support!

I hope your transition from the holiday spirit to getting back to work has been smooth :P Here’s the second newsletter of the year!

Interesting links for the week

Instead of sending a bunch of random links your way, these are all things I’ve read or seen and found interesting and relevant enough to share!

  • A list of new(ish) command line tools

  • How DOOM fire was done

  • Introduction To Terraform

  • Why make software?

Something that sparked my curiosity

I’ll be honest—when I first started learning how to program, I hated going through data structures and algorithms. It felt like a complete waste of time compared to actually building something with code.

But a couple of months ago, I came across a problem on arrays that someone had posted about on Twitter, and I decided to give it a shot. To my surprise, I actually had fun solving it, so I started doing more. It became like a puzzle, and I developed some interest.

Fast forward to today, I find myself learning about data structure and algorithm fundamentals I previously ignored, and I’m actually enjoying the process. I’m implementing everything in Go and creating a markdown book using mdBook. I’m really excited to share this with you all once I’ve made some more progress on it!

Golang puzzle of the week

Spider-Man needs to navigate through a web of nodes (a singly linked list). Each node represents a building, and Spider-Man must swing from one to the next. Unfortunately, the web is broken. One of the links in the list is incorrect! Your goal is to help Spidey fix it and reach the final node by completing the FixWeb function.

You’re only expected to change the FixWeb function, nothing else.

package main

import "fmt"

type Node struct {
    Value int
    Next  *Node
}

func FixWeb(head *Node) {
    // write your code here
}

func PrintWeb(head *Node) {
    current := head
    for current != nil {
        fmt.Printf("%d -> ", current.Value)
        current = current.Next
    }
    fmt.Println("nil")
}

func main() {
    // spiderman's broken web
    node1 := &Node{Value: 1}
    node2 := &Node{Value: 2}
    node3 := &Node{Value: 3}
    node4 := &Node{Value: 4}

    node1.Next = node2
    node2.Next = node3
    node3.Next = node4
    node4.Next = node2 // broken link

    fmt.Println("Original Web:")
    PrintWeb(node1) // this needs to be fixed, it won't terminate

    FixWeb(node1)

    fmt.Println("Fixed Web:")
    PrintWeb(node1) // should print a proper list
}

You can write solutions to this in the Go Playground and share the link with me on LinkedIn to get a shoutout in next week’s newsletter!

Who’s hiring?

  • SigNoz is hiring for a Product Marketing role and Frontend Engineer role (remote).

  • Kong is hiring for a bunch of Software Engineering roles in India.

  • Pulumi is hiring for a remote Senior Software Engineer in United States or Europe.

Don't miss what's next. Subscribe to Arsh's Newsletter:
Blog X LinkedIn
This email brought to you by Buttondown, the easiest way to start and grow your newsletter.