FIND YOUR NEXT FEW LINES

Results for “k”

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

1871 snippets foundClear filters
Arduino / CDigital signals & interrupts

Stop receiving interrupts when a task finishes

Arduino / C: detachInterrupt removes the registered callback.

Arduino / C✓ Tested
GitRestoring & revising local work

Stop tracking a generated file while keeping it locally

Git: Removing a path from the index leaves its working copy intact when cached is specified.

Git✓ Tested
CSSInteraction selectors

Style content associated with a checked option

CSS: The adjacent-sibling selector connects a checked control with its following label text.

CSS✓ Tested
CSSTypography

Style list markers

Set marker color separately from list text using CSS ::marker.

CSS✓ Tested
HTMLMetadata & document links

Supply a title and URL for link previews

HTML: Open Graph metadata describes a shared page without changing its visible content.

HTML✓ Tested
PythonIteration & sequences

Take a limited number of iterator values

Python: Use islice to consume only the requested prefix of a potentially unbounded iterator.

Python✓ Tested
JavaStream transformations

Take a page from a stream

Java: Use skip and limit with a known stable input order.

Java✓ Tested
C#LINQ transformations

Take a page from an ordered sequence

C#: Apply a stable order before Skip and Take for predictable paging.

C#✓ Tested
JavaQueues & collection operations

Take an immutable list snapshot

Java: List.copyOf protects the snapshot from later changes to the source list.

Java✓ 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
GitInspecting the working tree

Test whether tracked working files changed

Git: A quiet diff returns status one for differences, so handle it in a conditional.

Git✓ Tested