FIND YOUR NEXT FEW LINES

Results for “run”

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

2246 snippets foundClear filters
JavaScriptGetting Started

Find what remains after division

JavaScript: Use the remainder operator to count items left after forming complete groups.

JavaScript✓ Tested
TypeScriptGetting Started

Find what remains after division

TypeScript: Use the remainder operator to count items left after forming complete groups.

TypeScript✓ Tested
C++Getting Started

Find what remains after division

C++: Use the remainder operator to count items left after forming complete groups.

C++✓ Tested
CGetting Started

Find what remains after division

C: Use the remainder operator to count items left after forming complete groups.

C✓ Tested
JavaScriptArray restructuring

Flatten a single nesting level

JavaScript: flat defaults to a depth of one and creates a new array.

JavaScript✓ Tested
TypeScriptArray restructuring

Flatten a single nesting level

TypeScript: flat defaults to a depth of one and creates a new array.

TypeScript✓ Tested
JavaStream transformations

Flatten nested collections

Java: Use flatMap to concatenate nested Java lists into one stream.

Java✓ Tested
RustIterators & transformations

Flatten nested collections

Flatten nested collections in a complete Rust program using the standard library.

Rust✓ Tested
C#LINQ transformations

Flatten nested collections with SelectMany

C#: Concatenate the items from several sequences into one sequence.

C#✓ Tested
PythonIteration & sequences

Flatten one level of nested lists

Python: Use a nested comprehension when each input item is itself an iterable.

Python✓ Tested
Docker / ComposeContainer lifecycle

Force a disposable container to stop

Docker / Compose: kill sends SIGKILL by default without a graceful shutdown interval.

Docker / Compose✓ Tested
PowerShellDates & numeric validation

Format a bounded duration as hours minutes and seconds

PowerShell: TimeSpan can format duration components with escaped separators.

PowerShell✓ Tested