async-algorithms

command
v0.0.5 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 18, 2025 License: Apache-2.0 Imports: 5 Imported by: 0

README

Asynchronous Algorithms

This example demonstrates parallel processing with async algorithms.

What it shows

  • MapAsync() - Transform elements in parallel
  • FilterAsync() - Filter elements in parallel
  • FlatMapAsync() - Expand elements in parallel
  • Performance benefits of parallel execution
  • Results may arrive out of order

Run

cd examples/async-algorithms
go run main.go

Key concepts

  • Each element is processed in a separate goroutine
  • Significant performance improvement for expensive operations
  • Results must be sorted if order matters
  • Best for I/O-bound or CPU-intensive transformations

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL