FIND YOUR NEXT FEW LINES

Results for “k”

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

1871 snippets foundClear filters
RustErrors & optional values

Handle integer overflow without panicking

Handle integer overflow without panicking in a complete Rust program using the standard library.

Rust✓ Tested
AngularEvents & DOM interaction

Handle the Enter key specifically

Handle the Enter key specifically with a standalone Angular component and explicit browser behavior.

Angular✓ Tested
Arduino / CGetting Started

Hello World: Blink

Arduino / C: Blink the built-in LED slowly and then quickly, repeating both rates in loop().

Arduino / C✓ Tested
AngularTemplates & bindings

Hide an element while keeping it mounted

Hide an element while keeping it mounted with a standalone Angular component and explicit browser behavior.

Angular✓ Tested
CSSBox dimensions & overflow

Hide an element while keeping its space

CSS: Visibility hidden preserves layout geometry even though the element is not painted.

CSS✓ Tested
CSSInteraction selectors

Highlight a group containing keyboard focus

CSS: Focus-within matches a parent when any descendant has focus.

CSS✓ Tested
HTMLText semantics

Identify the title of a cited work

HTML: Cite marks the title of a work rather than the name of its author.

HTML✓ Tested
GitStashing selected work

Include untracked files in a stash

Git: The include-untracked option saves new files along with tracked edits.

Git✓ Tested
JavaStream transformations

Index records by a unique key

Java: Use toMap with an explicit merge rule so duplicate keys have defined behavior.

Java✓ Tested
C++Containers & compound values

Insert a map value only when a key is absent

C++: try_emplace preserves the old value when insertion does not take place.

C++✓ Tested
Docker / ComposeLimits & process security

Insert Docker’s small init process

Docker / Compose: The init option adds a PID 1 process that reaps children and forwards signals.

Docker / Compose✓ Tested
SQLBulk changes & set operations

Insert only keys absent from a destination

SQL: NOT EXISTS supports a set-based missing-row insert in a single-writer example.

SQL✓ Tested