FIND YOUR NEXT FEW LINES

Results for “save file”

Small, practical examples. Search by task or narrow things down below.

1970 snippets foundClear filters
RustIterators & transformations

Partition values into two collections

Partition values into two collections in a complete Rust program using the standard library.

Rust✓ Tested
PowerShellFunctions & parameter validation

Pass a block of behavior as an argument

PowerShell: Invoke a scriptblock with the call operator and an explicit input value.

PowerShell✓ Tested
PowerShellCommands & execution context

Pass an environment value to a child process

PowerShell: The process environment is inherited by a launched child PowerShell process.

PowerShell✓ Tested
Docker / ComposeCompose service options

Pass dollar expressions through Compose

Docker / Compose: Double dollar signs defer expansion to the container shell.

Docker / Compose✓ Tested
PowerShellFunctions & control

Pass named parameters from a hashtable

Keep a command’s options together in a reusable object.

splatting✓ Tested
GoSlices & collections

Preallocate a slice’s capacity

Preallocate a slice’s capacity using a complete Go program with explicit sample inputs.

Go✓ Tested
PowerShellFunctions & parameter validation

Preserve a failure after local cleanup

PowerShell: A bare throw inside catch rethrows the current exception.

PowerShell✓ Tested
GoJSON & encoding

Preserve a large JSON integer

Preserve a large JSON integer using a complete Go program with explicit sample inputs.

Go✓ Tested
PowerShellHashtables & object records

Preserve key insertion order

PowerShell: An ordered dictionary enumerates keys in the order they were inserted.

PowerShell✓ Tested
RustGetting Started

Print a collection for inspection

Print a collection for inspection in a complete Rust program using the standard library.

Rust✓ Tested
RustVectors & slices

Process a slice in bounded chunks

Process a slice in bounded chunks in a complete Rust program using the standard library.

Rust✓ Tested
PowerShellGetting Started

Process every array element

PowerShell: Process every array element using PowerShell 7.

PowerShell✓ Tested