Explore >> Select a destination


You are here

rakyll.org
| | mfbmina.dev
11.7 parsecs away

Travel
| | One of my favorite features in Go is the possibility of writing benchmark tests. At Go 1.24, this feature has a new look, making it easier to use. To demonstrate these changes, let's suppose a function that calculates the factorial recursively and one that calculates it through loops. func FatorialRecursive(n int) int { if n == 0 { return 1 } return n * FatorialRecursive(n-1) } func FatorialLoop(n int) int { aux := 1 for i := 1; i <= n; i++ { aux *= i } return aux } Previously, to write a benchmark, it was necessary to write down the whole execution loop of the test. When done, we need to run the command $ go test -bench .
| | zackoverflow.dev
9.1 parsecs away

Travel
| | Interfaces rely on slow dynamic-dispatch, but generics could open the door to performance boosts with the ability to leverage the cache-friendliness of static dispatch
| | lukesingham.com
11.2 parsecs away

Travel
| | These are my summary notes of 'A Tour of Go' - which is meant for people who are familiar with programming to have a quick tour
| | www.jeremymorgan.com
82.5 parsecs away

Travel
| In this guide, we will explore the different ways to convert a string into bytes in Python. We will discuss the most common methods and their applications, as well as provide examples and code snipp ...