- 52
- 267 009
Flo Woelki
Germany
Приєднався 30 тра 2012
Creating content about software engineering with Emojis and Paper.
The Must pattern in Golang clearly explained!
DISCLAIMER: This video only demonstrates the usage of the Must pattern, which should simplify a few things with your error handling. However, it does not praise the usage of `panic,` and you should not use it except if you are 100% sure that an error should not occur (e.g., where the programmer does the input, like in the regex example).
You must use this custom functionality in Golang more often to reduce your error-checking code! In this video, I'll explain the must concept and how you can leverage it in your codebase. If you are also curious about more ways to handle errors: ua-cam.com/video/4qU6FyrMUQw/v-deo.html
📝 Description
In this video, I'll show you the function you might have never seen before but you might need in your codebase. Especially when you have to deal with a lot of redundant error checking. In this video, you will learn the following things:
• How we can reduce error checks in Golang
• What is the `must` concept in Golang is
• What are the advantages and disadvantages of the `must` concept in Golang
⏳ Timestamps:
00:00 - Introduction
01:13 - Example 1
07:02 - Example 2
15:00 - Outro
Correction:
01:20 DISCLAIMER: This video only demonstrates the usage of the Must pattern, which should simplify a few things with your error handling. However, it does not praise the usage of `panic,` and you should not use it except if you are 100% sure that an error should not occur (e.g., where the programmer does the input, like in the regex example).
👋 Hey there!
If you are new to this channel: Hey 👋 my name is Flo and I am a professional software engineer with a passion for coding in Golang, TypeScript, JavaScript, and Rust. This channel is where I share that passion and dive into the exciting world of software engineering. Plus, I love using emojis and paper-based animations (so have a look for that if you want to find my videos).
📨 Support and Connect!
Buy me a coffee: www.buymeacoffee.com/florianwoelki
Become a member. www.youtube.com/@FloWoelki/membership
Discord: discord.gg/TnA7drJ
Instagram: flowydev
LinkedIn: www.linkedin.com/in/florian-woelki/
TikTok: www.tiktok.com/@florianwoelki
GitHub: github.com/FlorianWoelki
📝 Copyright Notice
The original Go Gopher version is originally designed by Renée French (Source: go.dev/blog/gopher License details: creativecommons.org/licenses/by/4.0/). The gopher used in the video and thumbnail is inspired by this author.
#golang #go #must
You must use this custom functionality in Golang more often to reduce your error-checking code! In this video, I'll explain the must concept and how you can leverage it in your codebase. If you are also curious about more ways to handle errors: ua-cam.com/video/4qU6FyrMUQw/v-deo.html
📝 Description
In this video, I'll show you the function you might have never seen before but you might need in your codebase. Especially when you have to deal with a lot of redundant error checking. In this video, you will learn the following things:
• How we can reduce error checks in Golang
• What is the `must` concept in Golang is
• What are the advantages and disadvantages of the `must` concept in Golang
⏳ Timestamps:
00:00 - Introduction
01:13 - Example 1
07:02 - Example 2
15:00 - Outro
Correction:
01:20 DISCLAIMER: This video only demonstrates the usage of the Must pattern, which should simplify a few things with your error handling. However, it does not praise the usage of `panic,` and you should not use it except if you are 100% sure that an error should not occur (e.g., where the programmer does the input, like in the regex example).
👋 Hey there!
If you are new to this channel: Hey 👋 my name is Flo and I am a professional software engineer with a passion for coding in Golang, TypeScript, JavaScript, and Rust. This channel is where I share that passion and dive into the exciting world of software engineering. Plus, I love using emojis and paper-based animations (so have a look for that if you want to find my videos).
📨 Support and Connect!
Buy me a coffee: www.buymeacoffee.com/florianwoelki
Become a member. www.youtube.com/@FloWoelki/membership
Discord: discord.gg/TnA7drJ
Instagram: flowydev
LinkedIn: www.linkedin.com/in/florian-woelki/
TikTok: www.tiktok.com/@florianwoelki
GitHub: github.com/FlorianWoelki
📝 Copyright Notice
The original Go Gopher version is originally designed by Renée French (Source: go.dev/blog/gopher License details: creativecommons.org/licenses/by/4.0/). The gopher used in the video and thumbnail is inspired by this author.
#golang #go #must
Переглядів: 6 227
Відео
Using slices in Rust is pretty powerful!
Переглядів 1,4 тис.28 днів тому
Slices is an easy yet powerful concept you must know in Rust! If you also want to understand the differences between String and &str, feel free to check out this video here: ua-cam.com/video/2Lzhx1_CTy8/v-deo.html 📝 Description Discover the power of slices in Rust - a fundamental feature that allows you to reference parts of collections without copying data! In this tutorial, you'll learn every...
Say Goodbye to Magic Numbers: Using "Enums" in Golang!
Переглядів 6 тис.Місяць тому
"Enums" in Golang are a special type that lets you create custom user-generated types to have more readable code! If you would like to know how to better secure your Go project, check out this video as well: ua-cam.com/video/eMAScRNHKx4/v-deo.html 📝 Description In this video, we dive deep into enums in Golang. Enums (short for enumerated types) are data types consisting of a predefined set of n...
Use this to check if your Go project is vulnerable!
Переглядів 1,9 тис.Місяць тому
This command provided by the Go security team lets you scan your codebase and its dependencies for critical vulnerabilities you have to fix! If you want to also create an HTTP server in Golang, check out this video as well: ua-cam.com/video/eqvDSkuBihs/v-deo.html 📝 Description In this video, we dive deep into the govulncheck command in Golang. This command lets you easily check if your Go proje...
Rust's Twin Strings: Understanding &str and String
Переглядів 1,4 тис.Місяць тому
Understanding the differences between the different String types in Rust can be quite challenging. This video will give you an introduction to the differences between &str and String. If you've enjoyed this video, feel free to watch this one about error handling in Rust: ua-cam.com/video/Z6wxawIPUaw/v-deo.html 📝 Description In this tutorial, we'll be diving into the world of Rust strings, focus...
Memory Profiling is so easy with Go's Runtime package!
Переглядів 4,1 тис.Місяць тому
The runtime package has an awesome way to measure and profile the currently used memory of your application or program! In this video, we'll explore the powerful runtime package and its MemStats feature. If you found this video helpful, check out this video about runes in Golang: ua-cam.com/video/1pOfYd0y6_4/v-deo.html 📝 Description In this video, we dive deep into the MemStats feature of the r...
Characters do not exist in Go: Everything about runes!
Переглядів 2,9 тис.2 місяці тому
There is a fundamental difference between characters and runes, and this video will clarify everything you need about runes in Golang. Timers and Tickers are also excellent, and I already made a video about them as well: ua-cam.com/video/pokwMUv5vwc/v-deo.html 📝 Description In this video, we dive deep into the concept of runes in Go programming. Learn why Go uses runes instead of characters and...
Control your errors in Golang with this module!
Переглядів 2,9 тис.2 місяці тому
Errors can be extraordinary in Golang, especially when you make use of the built-in errors module! Timers and Tickers are also wonderful and I already made a video about them as well: ua-cam.com/video/pokwMUv5vwc/v-deo.html 📝 Description Errors can be relatively annoying and scary for beginners. However, the errors module gives you a brilliant way to deal with custom errors and built-in errors....
Beyond the Clock: All about Timers & Tickers in Golang!
Переглядів 2 тис.2 місяці тому
Golang Timers & Tickers are powerful concepts you must learn to get comfortable with Golang and sensitive time actions! An interesting new feature in Golang is custom iterators. Check out this video if you are interested: ua-cam.com/video/iurUVx0Nquc/v-deo.html 📝 Description Dive into the world of Go's powerful time management tools with this comprehensive guide to Timers and Tickers. Perfect f...
Go 1.23: Custom Iterators Explained - Best feature?!
Переглядів 4,7 тис.2 місяці тому
Iterators in Go 1.23 can sometimes be confusing, but ultimately, they are absolutely amazing and will transform the Go library developer's life! If you are interested in how to boost your Go application's performance, feel free to check out this video: ua-cam.com/video/4oJ08j3mzH0/v-deo.html 📝 Description Discover the latest feature in Go 1.23 that's changing how we handle iterations: Custom It...
Boosting the performance by being unique in Go 1.23!
Переглядів 6 тис.2 місяці тому
Understanding the unique module in Go 1.23 is an absolute must because it will improve your performance! While this module is interesting, there have been some changes with sorting and timers as well, so feel free to check out this video: ua-cam.com/video/MVx_b-2TuLY/v-deo.html 📝 Description Go 1.23 is here, and it's bringing some exciting changes! In this video, we'll dive deep into one of the...
You have to know these two Golang 1.23 changes!
Переглядів 3,9 тис.3 місяці тому
The new sorting and timer functionalities are crucial to understand in Go 1.23 because they offer much more flexibility. If you also need a quick refresher on Golang, feel free to check out this video here: ua-cam.com/video/P7dCWOjRwJA/v-deo.html 📝 Description In this video, we'll dive into the sweet and meaty updates of Go 1.23, where we clarify two significant changes related to sorting and t...
Building a CLI with Rust and the GitHub API is so easy!
Переглядів 1,6 тис.3 місяці тому
A real-world use case for Rust would be to interact with the GitHub API to retrieve all repository issues and their reactions and sort them based on upvotes. This is what we are going to build today! Also, if you want to learn more about the `?` operator in Rust, feel free to check out this video: ua-cam.com/video/Z6wxawIPUaw/v-deo.html 📝 Description In this tutorial, we will be diving into a r...
Type Assertions in Go: the only guide you need!
Переглядів 3,2 тис.3 місяці тому
Type Assertions and the Type Switch in Go are concepts that you need to understand to fully master any types in Golang! If you also need a quick refresher of Golang, feel free to check out this video here: ua-cam.com/video/P7dCWOjRwJA/v-deo.html 📝 Description Struggling with determining variable types in Go interfaces? This video dives deep into type switches and type assertions - powerful tool...
A hands-on guide for proper Unit Testing in Go!
Переглядів 5 тис.3 місяці тому
Unit testing is an essential part of scaling an application and getting a good night's sleep. This video contains explanations that include Structs, if you need a refresher what structs are, check out this video: ua-cam.com/video/c8H0w4yBL10/v-deo.html 📝 Description In this video, we're diving deep into the world of unit testing in Golang. Whether you're building scalable applications or robust...
If you are a beginner in Go, avoid this Slice pitfall!
Переглядів 4,9 тис.4 місяці тому
If you are a beginner in Go, avoid this Slice pitfall!
Creating custom struct tags in Golang is awesome!
Переглядів 10 тис.4 місяці тому
Creating custom struct tags in Golang is awesome!
Level Up Your Golang: 5 Concepts You Need to know
Переглядів 13 тис.4 місяці тому
Level Up Your Golang: 5 Concepts You Need to know
Why I switched from VSCode to Zed.
Переглядів 34 тис.5 місяців тому
Why I switched from VSCode to Zed.
The Spread Operator (or Variadic Functions) in Golang
Переглядів 1,7 тис.5 місяців тому
The Spread Operator (or Variadic Functions) in Golang
DIY Golang Web Server: No Dependencies Needed!
Переглядів 11 тис.5 місяців тому
DIY Golang Web Server: No Dependencies Needed!
Golang: The Last Interface Explanation You'll Ever Need
Переглядів 22 тис.5 місяців тому
Golang: The Last Interface Explanation You'll Ever Need
Defer Functions In Golang: Everything You Need To Know
Переглядів 1,7 тис.5 місяців тому
Defer Functions In Golang: Everything You Need To Know
You are providing fallback values in Golang wrong!
Переглядів 3,1 тис.6 місяців тому
You are providing fallback values in Golang wrong!
Actix Web Extractors: JSON, Query, Path Param, and Form
Переглядів 8416 місяців тому
Actix Web Extractors: JSON, Query, Path Param, and Form
This is your last video about Golang Structs!
Переглядів 9 тис.6 місяців тому
This is your last video about Golang Structs!
The lesser-known Symbol in JavaScript and TypeScript
Переглядів 4796 місяців тому
The lesser-known Symbol in JavaScript and TypeScript
How Go 1.22 fixed an issue that caused Google problems
Переглядів 2,1 тис.7 місяців тому
How Go 1.22 fixed an issue that caused Google problems
Rust error handling made easier with the ?-operator
Переглядів 1,6 тис.7 місяців тому
Rust error handling made easier with the ?-operator
Why HTMX and Golang? The answer might surprise you...
Переглядів 15 тис.7 місяців тому
Why HTMX and Golang? The answer might surprise you...
Thank you! I've found a lot of examples out there, but I was able to understand how that works just now
That's so awesome to hear :) Glad it helped!
Thanks brother Have u made any playlist teaching complete go lang course If yes plz mention
Yeah just look at my channel :p
lol, why don't you use Arc::clone() along with Arc:new()?
Mach doch Videos auf deutsch. Gute englische Kanäle gibts schon ohne Ende, professionelle deutsche besonders für Rust nicht so
It's fcked! 🤢
Thank you, i really love your content and your manner of explanation :)
Greeting from Brazil 👋🇧🇷 Excellent video, your didactic is really good. Thanks for your work!
Hello there :) Thank you so much for watching!
I want to love go but it sucks :( , it doesnt have typesafe enums, readonly props, marker interfaces, explicit interface decl, discriminated unions, required fields, pattern matching, adhoc polymorphism...
no nameof(), no optional parameters
no default field values in structs
Damn man, that was a direct hit. So clear and tqsm
12:03 Wow did not know that, thank you!
Me too. I'm wondering if there is a max depths for this
This cursor block shape is a nightmare
iota makes me uncomfortable. Someone changes the order indirectly, you get a subtle bug.
Thank you for sharing this concept. (As you know, nested blocks of code are against best practices and clean principles.)
Absolutely! I was sharing a really simplified example so that everyone can follow :)
Very good video, I didn't understood 5:50 (binary prefix, SI unit ...), can you provide some resources?
One thing to note, you can use += with mut String's but not &str's, mut or not. It doesn't make sense to me, and I feel it was the wrong direction for them to take the design, but I also don't think there are many languages which get strings correct. Another pain point, since strings are UTF-8 encoded, .len() doesn't report the correct number of characters in the string but instead reports the number of bytes, which is fine for allocation purposes, but nothing else. I don't know if anyone else would agree, but I think that strings should have been treated as first class objects and default to a string_view type of some kind. Of course, I also wouldn't design things around explicit borrowing and ownership rules, but I can't imagine any Rustacean will agree with that stance.
This gives me a lot to ponder. Is it more important to have a consistent error handling technique, like always use `r, err := foo(); if err != nil ...` or would it not make sense in certain circumstances to change the methodology when the return value is both the error and desired object? Consider the C way of doing things where the return value is a pointer to something and if the operation failed the pointer is NULL. So merely checking the return is how you determine if you can go on. `FILE *f; f = fopen( "some_file.txt", "rb" ); if ( !f ) ...` Also, if you call panic() in Go, do deferred operations still execute or do they get skipped?
Unless im missing something, its Honestly a bad design by Go designers. How would I know what interfaces a type implements off the bat ?
You are not missing anything! I personally also think that it is not always 100% clear if a struct uses a specific interface. I like more the explicit design, like in other languages.
For case 2, when you want to return an error, it is possible to use Must, CheckErr but also add a deferred statement with recover at the beginning. If this statement is coupled with a named error argument, you can modify it and return the error. Is this a bad practice?
Honestly I think posting this video as-is was rather irresponsible. Too often you show Must() w/panic() and imply it is a good practice because of how it "simplifies the code." Viewers who don't watch the entire video or who are not good at noticing nuance, and who don't read the comments will likely see your praise of Must()+panic() and leave thinking it a practice they should emulate. On the contrary, there are very few use-cases where panic should ever be used, and certainly not in code intended for production use. IMO you really should add a very obvious disclaimer to the beginning of the video saying you "were just showing how Must() works, but please do not ever actually use it for anything other than personal use or for testing." #fwiw
Thank you for the feedback! I've added a few disclaimers (descriptions and an info card). I hope that this is enough.
Not enough. At least change the text on the thumbnail from "You Must use this" to "Must you use this?" or similar. That thumbnail sets the tone of the video to be about a best practice rather than a cautionary tale.
I'll see what I can do here :)
@@FloWoelki - Kudos for the responsiveness to criticism.
I found your channel just days back and I can’t thank you enough for these videos!! This is great!! 😭
Wow, thank you so much! I greatly appreciate it!
Why did we use generic types here?
Which extenshion you use for error intellicence which show issue in the front of error line
I truly think this Must function version with generics should be on the standard library. I always write it myself in almost all my projects.
Yeah, I kind of agree; there was also an open discussion on GitHub about that. It's kind of similar to this issue here: github.com/golang/go/issues/32437
I learnt something new thanks. I think it's a great video, as usual!. Disagreeing with things =/= bad video :)
Thank you, and I am glad that you've learned something! :)
Yeah yeah naaaaah, don't use Go if you don't want to handle errors as values. Must function is a very precise knife. To be used carefully. Error as values is the spirit of GO. If you don't accept it you will just be fighting the language
I agree, and I also enjoy using Golang. Since this topic is still being discussed in the community, I wanted to highlight it and make a video about it.
Love the golang kids crying that you must handle errors when using golang. This pattern is effectively an assert, and you use asserts in cases where you need to crash. For static content known at compile time, like a fucking regex, this decreases verbosity and increases the readability.
Except regexp already has a MustCompile(), and while I am sure due to the difficulty of proving a negative there is at least one other similar scenario where there is not a built-in "Must" I cannot actually think of any. Maybe you can think of one?
If you don't want to check erors don't use Go. Explicit errors are THE philosophy of Go.
Please don't use log.Fatal... Especially if your writing a module to be used by others. Some things to remember. Log.Fatal terminates the program immediately. Panic will run any defers and can be recovered.
I think errors as return values is one of the strong points of the language. That it tends to result in the ubiquitous `if err != nil` and that there is no ternary operator or other facility to deal with it in another way is another and long-standing discussion :-)
👉👉👉Panic() is NOT error handling. Golang handles exceptions through the Panic+Recover mechanism. PLZ Do not mix concepts.
Timers & Tickers? Game devs: "I now this one!"
Are you using zed editor 😅? Great video btw!
Thank you and yes :)
I get it, go has very verbose error handling to a point where it makes code harder to read. After doing some rust one feels the pain even more. But look this is go, and the good side of it is that any junior dev can look at the code and figure out what’s going on. And has less ways to screw error handling up when following some simple guidelines. One of them is “don’t panic”. So I think this makes things complicated by hiding logic away and it will either confuse someone or it’s likely that Must() will be used where it shouldn’t. So I’d advice to just keep things the go way or use another language. Otherwise there’s really no point because you get the worst and miss the benefits mixing it all up.
I usually like your content but I think this video is a bit off. panic in go is an anti pattern and really should be avoided at all costs. There is only 1 reason to use a panic and that is if the code is going to panic anyway then issue a panic with a helpful message; ie if you are about to dereference a nil pointer then it’s ok to panic with a meaningful message rather than allow a generic nil reference panic to occur which is harder to debug. I don’t think you have appreciated how bad using panics is. Use the error checking mechanism, that’s what it’s there for. Depending on panic and recover is just asking for trouble
I really appreciate your feedback, and I 100% agree. I've mentioned multiple times throughout the video that you always have to be careful when using panic, but maybe that wasn't enough. I just wanted to focus on the must pattern itself. Although it is obviously also used throughout the Golang codebase where the Must pattern is also used, but yeah having detailed error messages without necessarily panicking would be much better.
Just be aware that wrapping your functions in other functions shouldn't be used in performance critical sections.
Sometimes it seems bad when insert same error check in multiple times within same block. But i read somewhere the best practice is that caller of the function should handle the errors. Hoping some improvement in the future.
I rather like the error checking in Go! If go just improved the syntax over if err != nil {} I honestly wouldn't have anything to complain about .
I think there are even some thoughts for "Go 2.0" where a more improved version of the error checking was proposed.
@@FloWoelki- The Go team announced they decided there would never be a "Go 2.0" as they originally discussed. They decided maintaining backward compatibility is the most important language attribute.
This is honestly a bad advice. wrapping your function calls with "Must" or "CheckError" isn't any cleaner. And "don't panic" is a go proverb. I agree with you that sometimes we just wanna bubble up the errors without necessarily handling them. For that I hope the Go team add some sugar ( like the Rust's "?" operator) to make it easy to do so.
Sure thing and thank you for the comment, but I would disagree with that. The "Must" pattern is a well-established convention in Golang for handling errors in specific scenarios. Although it's a fair point with the panic, I've mentioned that throughout the whole video. Must functions should be used judiciously, as they convert recoverable errors into panics, which can crash your program if not handled properly. There is even a `Must` function inside the Golang codebase: cs.opensource.google/go/go/+/refs/tags/go1.23.3:src/text/template/helper.go;l=24
I think panic is great when the state is truly unrecoverable. By the same token I think recover is more like an option for even more rare cases.
@@FloWoelki The Must functions that use the one you describe are only intended to be used during initialization and when you are 99.99% sure your program won't crash, e.g. MustCompile(regex) when your regex is static and won't change. You are defending a stance you don't fully understand.
I strongly disagree. It is my humble opinion that error handling in Go is excellent. I think that panic is not error handling and should not be used like an exception. Edit: Once again you continue to impress. This video is an excellent treatment of the topic. Everyone, please watch to the end as the entirety of this video is important.
I think everyone has their opinion about the Golang error handling, but I agree with you. And Golang does not even have traditional exceptions :D I've also added a "* kind of" to the "sucks" and I think that "sucks" was harsh wording, but thank you though. Btw. I've also said multiple times throughout the video that everyone should be careful when using "panic", but thanks for the comment! Appreciate the honesty!
@@FloWoelki Yes some can think panic is an exception in disguise because you can in a defer function basically recover and cancel the panic but the intent behind panic is completely different than Exception. Exception you base your whole project to be prepared at one stage to catch and mange the error like in an HTTP controller. With exception you arrived at a point of execution in your program where something really unexpected and unfixable occurred. In this case the only thing you can do is displaying errors message and stop with panic the whole program. Maybe your golang Mux will just make sure for your http route to just kill the goroutine and return 500 but the idea of you can’t continue persist.
panic ARE exceptions when you need to skip the stack trace. Go error hanlding is so much better than traditional try--catch throw. When you query an endpoint and you get an "error", you get an error VALUE. It is not logical to raise an exception just to signal that something wrong has happened. On the other hand, you start your application and you cannot connect to your database. If your application CAN function without the database, then there is no need to raise an exception. It is just an error value. If it cannot, there is no need to travel the whole stack back to the originating call. You raise an exception (panic) and you either exit, or recover, maybe try a second and a third time. Go's error handling is actually one of its best features.
Danke, du solltest den genialen Content auch in deutsch bringen, wir brauchen mehr deutsche GoLangDevs
I don't see these error checks as "redundant" if they are there then we can follow the "happy path" and "sad path" only when there is something not working aka throwing an error. This reduces the cognitive load on the reader and make the code easier to read. Any other option is basically hiding the information and the Golang is not about that. I bet that's why some people were opposing the generics in the first place.
I think the same. I just wanted to say that, especially if you have a larger function and want to bubble the error up, the error checks, how they are written, are just redundant.
@@FloWoelki Love Your videos about the Golang, don't stop! Have a nice day, mate!
Appreciate it, thank you! :) Have a lovely day as well!
Seitdem im Oktober Zed für Linux veröffentlicht wurde, nutze ich das nur noch in meinem Elektrotechnik-Studium, extremes Tool. Ich hoffe allerdings das in Zukunft noch Plattformio das ganze ach akzeptiert bzw. eine extension dafür erstellt und das z.B. Laravel mehr Extensions hinzufügt (neben PHP Intellisense)
Very professional content. Great presentation also. Bravo Flo
Thank you so much for the feedback :)
@@FloWoelki I really am learning GO for Pulumi, but my higher purpose is elsewhere. Can you do a go light course covering the things we would need for Pulumi?
Hype is the word came to my mind.
That's a great example. I wonder if in real code bases people manually write out the validation like you did or if they're using a library like go validator. Coming from JS that looks like a lot of code for simple validation lol.
I'm new to Go and your video's help me a lot, thanks 🙏. Keep it up 💪
Glad to hear it! Thank you so much :)
You should also have shown the inclusive syntax for slicing which uses ..= so that the end index is included. For example, let v = vec![0, 1, 2, 3, 4]; let s = &v[1..=3]; and you get [1, 2, 3]. I don't understand their rationale for this design choice since I think that .. should be an inclusive range, but I assume it's because they didn't think of using other symbols. For my own language, I opted to use .. for inclusive slicing, : for start and length slicing, and commas for selection. I don't know if it's too late to get someone working on Rust to incorporate this idea, but an example of its usage would be: v := [1, 2, 3, 4, 5, 6], inclusive_slice = v[1..3], start_plus_length = v[1:2], selections = v[1,3,5]; then the results would be [2,3,4], [2,3], [2,4,6].
what is the name of the font you are using, I love your videos by the way 💥
The font is called Monaspace :) Thank you for watching! :)