FIND YOUR NEXT FEW LINES

Results for “at”

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

2630 snippets foundClear filters
JavaNumbers & dates

Sum integer values

Reduce a Java integer stream to its sum.

Java✓ Tested
JavaScriptArrays

Sum numeric values

Provide an initial accumulator for JavaScript reduce, including empty arrays.

JavaScript✓ Tested
TypeScriptCollections & records

Sum typed values with reduce

Accumulate numeric array elements.

reduce✓ Tested
C++Numbers & algorithms

Sum vector values

Use std::accumulate with a wide initial value.

C++✓ Tested
Docker / ComposeCompose service options

Supply a default for an unset Compose variable

Docker / Compose: The default interpolation form supplies a value when the variable is absent or empty.

Docker / Compose✓ Tested
ReactGetting Started

Supply a default prop value

Supply a default prop value with a small React component and explicit browser behavior.

React✓ Tested
CDynamic memory & ownership

Swap owned buffers by swapping their pointers

C: Pointer swaps avoid copying the underlying data.

C✓ Tested
RustStrings & Unicode

Take Unicode characters without byte slicing

Take Unicode characters without byte slicing in a complete Rust program using the standard library.

Rust✓ Tested
GitBranches & recovery

Temporarily store tracked-file edits

Restore a clean working tree and then reapply your saved changes.

stash✓ Tested
GoHTTP & URLs

Test an HTTP handler without a server

Test an HTTP handler without a server using a complete Go program with explicit sample inputs.

Go✓ Tested
Bash ScriptsText parsing & arithmetic

Test numeric divisibility with a remainder

Bash Scripts: The modulo operator computes an integer remainder.

Bash Scripts✓ Tested
GoGetting Started

Test whether a number is even

Test whether a number is even using a complete Go program with explicit sample inputs.

Go✓ Tested