Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/ardanlabs/gotraining
/ functions
Functions
1,474 in github.com/ardanlabs/gotraining
⨍
Functions
1,474
◇
Types & classes
404
↓ 1 callers
Function
simulation
simulation runs n games and return the fraction of games where "stay" strategy won and fraction where "switch" strategy won
topics/go/algorithms/simulations/monty/monty.go:25
↓ 1 callers
Function
single
single uses a single goroutine to perform the merge sort.
topics/go/testing/benchmarks/validate/validate_test.go:43
↓ 1 callers
Function
stackCopy
stackCopy recursively runs increasing the size of the stack. go:noinline
topics/go/language/pointers/example5/example5.go:20
↓ 1 callers
Method
start
start turns the chatroom on.
topics/go/concurrency/patterns/chat/chat.go:132
↓ 1 callers
Function
stayWinsGame
stayWinsGame is a single simulation of game. It return true if "stay" strategy wins.
topics/go/algorithms/simulations/monty/monty.go:11
↓ 1 callers
Function
store
store knows how to store bulks of data from any Storer.
topics/go/design/composition/decoupling/example3/example3.go:102
↓ 1 callers
Function
store
store knows how to store bulks of data from any Storer.
topics/go/design/composition/decoupling/example6/example6.go:88
↓ 1 callers
Function
store
store knows how to store bulks of data from any Storer.
topics/go/design/composition/decoupling/example2/example2.go:96
↓ 1 callers
Function
store
store knows how to store bulks of data from any Storer.
topics/go/design/composition/decoupling/example4/example4.go:102
↓ 1 callers
Function
store
store knows how to store bulks of data into Pillar.
topics/go/design/composition/decoupling/example1/example1.go:84
↓ 1 callers
Function
store
store knows how to store bulks of data from any Storer.
topics/go/design/composition/decoupling/example5/example5.go:96
↓ 1 callers
Function
stringifyCustomers
(customers []customer)
topics/go/generics/04-behavior-constraint/generic.go:46
↓ 1 callers
Function
stringifyUsers
============================================================================= These functions implement a stringify function that is specific to each
topics/go/generics/04-behavior-constraint/generic.go:38
↓ 1 callers
Function
swapInteger
============================================================================= These functions are concrete versions of a swap function. For each type
topics/go/generics/08-swapping/generic.go:11
↓ 1 callers
Function
swapInterface
============================================================================= This function provides an empty interface solution to perform a generic
topics/go/generics/08-swapping/generic.go:27
↓ 1 callers
Function
swapString
(v1 string, v2 string)
topics/go/generics/08-swapping/generic.go:16
↓ 1 callers
Function
sweep
(numbers []int, currentPass int)
topics/go/algorithms/sorting/bubble/bubble.go:70
↓ 1 callers
Function
teardown
()
topics/go/videos/miki/shorts/test_main/main_test.go:33
↓ 1 callers
Function
testPanic
testPanic simulates a function that encounters a panic to test our catchPanic function.
topics/go/language/functions/advanced/example1/example1.go:22
↓ 1 callers
Function
thirdCall
thirdCall create an error value we will validate.
topics/go/design/error_handling/example6/example6.go:66
↓ 1 callers
Function
thirdCall
thirdCall create an error value we will validate.
topics/go/design/error_handling/example7/example7.go:81
↓ 1 callers
Function
toType
topics/go/videos/miki/building/embed/static/bootstrap.js:42
↓ 1 callers
Method
toggle
()
topics/go/videos/miki/building/embed/static/bootstrap.js:1716
↓ 1 callers
Method
toggle
(event)
topics/go/videos/miki/building/embed/static/bootstrap.js:3681
↓ 1 callers
Function
unBuffered
With unbuffered channels, the receive happens before the corresponding send. The write to a happens before the receive on c, which happens before the
topics/go/concurrency/channels/advanced/example1/example1.go:20
↓ 1 callers
Function
unlimited
unlimited uses a goroutine for every split to perform the merge sort.
topics/go/testing/benchmarks/validate/validate_test.go:64
↓ 1 callers
Method
updateAttachment
(attachment)
topics/go/videos/miki/building/embed/static/bootstrap.js:3937
↓ 1 callers
Function
updateUser
updateUser updates the specified user document.
topics/go/language/functions/example2/example2.go:47
↓ 1 callers
Function
uppercase
uppercase displays the set of uppercase letters three times.
topics/go/concurrency/goroutines/example1/example1.go:59
↓ 1 callers
Function
urlSig
(ctx context.Context, url string)
topics/go/algorithms/md5/dlhash.go:12
↓ 1 callers
Function
validate
validate performs data validation on any struct type value.
topics/go/packages/reflection/exercises/exercise1/exercise1.go:36
↓ 1 callers
Function
validate
validate performs data validation on any struct type value.
topics/go/packages/reflection/tag/tag.go:44
↓ 1 callers
Function
validateAddr
(addr string)
topics/go/videos/miki/interfaces/flag/flag.go:31
↓ 1 callers
Function
valueOf
(c Celsius)
topics/go/videos/miki/interfaces/escape/weather/bench_test.go:17
↓ 1 callers
Function
valueOfIface
(v Value)
topics/go/videos/miki/interfaces/escape/weather/bench_test.go:21
↓ 1 callers
Function
waitForResult
waitForResult: In this pattern, the parent goroutine waits for the child goroutine to finish some work to signal the result.
topics/go/concurrency/channels/example1/example1.go:50
↓ 1 callers
Function
webCall
webCall performs a web operation.
topics/go/design/error_handling/example2/example2.go:42
↓ 1 callers
Function
webCall
webCall performs a web operation.
topics/go/design/error_handling/example1/example1.go:40
↓ 1 callers
Function
wrapHandler
(h Handler)
topics/go/language/pointers/flaws/example2/example2_http_test.go:26
↓ 1 callers
Method
write
write is a goroutine to handle processing outgoing messages to this client.
topics/go/concurrency/patterns/chat/chat.go:71
↓ 1 callers
Function
writer
writer adds 10 new strings to the slice in random intervals.
topics/go/profiling/mutex/mutex_test.go:51
↓ 1 callers
Function
writer
writer adds a new string to the slice in random intervals.
topics/go/concurrency/data_race/example4/example4.go:59
Method
Add
Add is using a value receiver and returning a value of type Time. This method is using value semantics for Time.
topics/go/language/methods/example5/example5.go:77
Method
Add
(a, b *Float64)
topics/go/generics/12-pointer-methods/generic.go:16
Method
AddBetter
AddBetter uses the `n` variable for the node. This variable is better because it doesn't get in the way of readability. Now the switch/case logic beco
topics/go/language/control_flow/example3/example3.go:42
Method
AddOk
AddOk uses the `newNode` variable for the node. This variable name gets in the way of readability. It becomes the focal point when trying to read the
topics/go/language/control_flow/example3/example3.go:20
Method
Amount
()
topics/go/videos/miki/interfaces/escape/weather/weather.go:13
Method
BehaviorAsContext
BehaviorAsContext shows how to check for the behavior of an interface that can be returned from the net package.
topics/go/design/error_handling/example4/example4.go:68
Function
BenchmarkAlgorithmFour
Capture the time it takes to execute algorithm four.
topics/go/packages/io/example4/example4_test.go:67
Function
BenchmarkAlgorithmOne
Capture the time it takes to execute algorithm one.
topics/go/packages/io/example4/example4_test.go:25
Function
BenchmarkAlgorithmOne
Capture the time it takes to execute algorithm one.
topics/go/profiling/memcpu/stream_test.go:21
Function
BenchmarkAlgorithmThree
Capture the time it takes to execute algorithm three.
topics/go/packages/io/example4/example4_test.go:53
Function
BenchmarkAlgorithmTwo
Capture the time it takes to execute algorithm two.
topics/go/packages/io/example4/example4_test.go:39
Function
BenchmarkAlgorithmTwo
Capture the time it takes to execute algorithm two.
topics/go/profiling/memcpu/stream_test.go:29
Function
BenchmarkAssignmentIndirect
(b *testing.B)
topics/go/language/pointers/flaws/example1/example1_test.go:5
Function
BenchmarkColumnTraverse
Capture the time it takes to perform a column traversal.
topics/go/testing/benchmarks/caching/caching_test.go:25
Function
BenchmarkConcrete
(b *testing.B)
topics/go/videos/miki/interfaces/escape/weather/bench_test.go:25
Function
BenchmarkConcurrent
(b *testing.B)
topics/go/testing/benchmarks/cpu-bound/cpu_test.go:33
Function
BenchmarkConcurrent
(b *testing.B)
topics/go/testing/benchmarks/io-bound/io_test.go:33
Function
BenchmarkConcurrentAgain
(b *testing.B)
topics/go/testing/benchmarks/cpu-bound/cpu_test.go:45
Function
BenchmarkConcurrentAgain
(b *testing.B)
topics/go/testing/benchmarks/io-bound/io_test.go:45
Function
BenchmarkConcurrentBounded
(b *testing.B)
topics/go/algorithms/fun/freq/freq_test.go:74
Function
BenchmarkConcurrentBoundedChannel
(b *testing.B)
topics/go/algorithms/fun/freq/freq_test.go:80
Function
BenchmarkConcurrentUnlimited
(b *testing.B)
topics/go/algorithms/fun/freq/freq_test.go:86
Function
BenchmarkDiameter
(b *testing.B)
topics/go/profiling/exercises/graphblog/node_test.go:91
Function
BenchmarkFormat
BenchmarkFormat provides performance numbers for the strconv.FormatInt function
topics/go/testing/benchmarks/exercises/exercise1/bench_test.go:32
Function
BenchmarkGlobal
BenchmarkGlobal tests the performance of 8 goroutines incrementing the global counter in parallel.
topics/go/testing/benchmarks/falseshare/falseshare_test.go:23
Function
BenchmarkHandler
(b *testing.B)
topics/go/language/pointers/flaws/example2/example2_http_test.go:8
Function
BenchmarkHeapSort
BenchmarkHeapSort a simple benchmark for the heap sort algorithm.
topics/go/algorithms/sorting/heap/heap_test.go:57
Function
BenchmarkIface
(b *testing.B)
topics/go/videos/miki/interfaces/escape/weather/bench_test.go:34
Function
BenchmarkInsertionSort
BenchmarkInsertionSort a simple benchmark for the insertion sort algorithm.
topics/go/algorithms/sorting/insertion/insertion_test.go:55
Function
BenchmarkInterfaces
(b *testing.B)
topics/go/language/pointers/flaws/example4/example4_test.go:15
Function
BenchmarkItoa
BenchmarkItoa provides performance numbers for the strconv.Itoa function
topics/go/testing/benchmarks/exercises/exercise1/bench_test.go:44
Function
BenchmarkLinkListTraverse
Capture the time it takes to perform a link list traversal.
topics/go/testing/benchmarks/caching/caching_test.go:14
Function
BenchmarkLiteralFunctions
(b *testing.B)
topics/go/language/pointers/flaws/example2/example2_test.go:7
Function
BenchmarkLocal
BenchmarkLocal tests the performance of 8 goroutines incrementing their local counter.
topics/go/testing/benchmarks/falseshare/falseshare_test.go:62
Function
BenchmarkNumCPU
(b *testing.B)
topics/go/testing/benchmarks/validate/validate_test.go:36
Function
BenchmarkPredictable
BenchmarkPredictable runs the test when the branch is predictable.
topics/go/testing/benchmarks/prediction/prediction_test.go:31
Function
BenchmarkQuickSort
BenchmarkQuickSort a simple benchmark for the quick sort algorithm.
topics/go/algorithms/sorting/quick/quick_test.go:57
Function
BenchmarkReverse
(b *testing.B)
topics/go/testing/strings/example4/reverse_test.go:51
Function
BenchmarkRowTraverse
Capture the time it takes to perform a row traversal.
topics/go/testing/benchmarks/caching/caching_test.go:36
Function
BenchmarkRssSearch
BenchmarkRssSearch provides support for profiling the search.
topics/go/profiling/project/search/rss_test.go:12
Function
BenchmarkSelectionSort
BenchmarkSelectionSort a simple benchmark for the selection sort algorithm.
topics/go/algorithms/sorting/selection/selection_test.go:55
Function
BenchmarkSequential
(b *testing.B)
topics/go/testing/benchmarks/cpu-bound/cpu_test.go:27
Function
BenchmarkSequential
(b *testing.B)
topics/go/testing/benchmarks/io-bound/io_test.go:27
Function
BenchmarkSequential
(b *testing.B)
topics/go/algorithms/fun/freq/freq_test.go:68
Function
BenchmarkSequentialAgain
(b *testing.B)
topics/go/testing/benchmarks/cpu-bound/cpu_test.go:39
Function
BenchmarkSequentialAgain
(b *testing.B)
topics/go/testing/benchmarks/io-bound/io_test.go:39
Function
BenchmarkSingle
(b *testing.B)
topics/go/testing/benchmarks/validate/validate_test.go:24
Function
BenchmarkSliceMapAssignment
(b *testing.B)
topics/go/language/pointers/flaws/example3/example3_test.go:5
Function
BenchmarkSprint
BenchmarkSprint tests all the Sprint related benchmarks as sub benchmarks.
topics/go/testing/benchmarks/sub/sub_test.go:20
Function
BenchmarkSprint
BenchmarkSprint tests the performance of using Sprint.
topics/go/testing/benchmarks/basic/basic_test.go:17
Function
BenchmarkSprintf
BenchmarkSprint tests the performance of using Sprintf.
topics/go/testing/benchmarks/basic/basic_test.go:28
Function
BenchmarkSprintf
BenchmarkSprintf provides performance numbers for the fmt.Sprintf function
topics/go/testing/benchmarks/exercises/exercise1/bench_test.go:20
Function
BenchmarkUnknown
(b *testing.B)
topics/go/language/pointers/flaws/example5/example5_test.go:8
Function
BenchmarkUnlimited
(b *testing.B)
topics/go/testing/benchmarks/validate/validate_test.go:30
Function
BenchmarkUnpredictable
BenchmarkUnpredictable runs the test when the branch is random.
topics/go/testing/benchmarks/prediction/prediction_test.go:45
Method
Close
()
topics/go/videos/miki/shorts/cleanup/cleanup_test.go:36
Method
Close
()
topics/go/videos/miki/building/embed/db.go:29
Method
Close
Close shutdown the chatroom and closes all connections.
topics/go/concurrency/patterns/chat/chat.go:189
← previous
next →
601–700 of 1,474, ranked by callers