FIND YOUR NEXT FEW LINES

Results for “k”

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

1871 snippets foundClear filters
Linux CommandsTransforming text

Reorder fields with a capture group

Linux Commands: Use extended regular expressions and backreferences to rearrange a known format.

Linux Commands✓ Tested
Bash ScriptsGetting Started

Repeat a command for several words

Bash Scripts: Repeat a command for several words with a small standalone Bash program.

Bash Scripts✓ Tested
Arduino / CGetting Started

Repeat a serial message three times

Arduino / C: Repeat a serial message three times on an Uno with the Serial Monitor set to 9600 baud.

Arduino / C✓ Tested
Arduino / CTiming & control

Repeat an action a fixed number of times

Use a counter and delay for a simple finite sequence.

for loop✓ Tested
Bash ScriptsArguments & decisions

Repeat until a condition becomes true

Bash Scripts: An until loop continues while its test returns a nonzero status.

Bash Scripts✓ Tested
RustGetting Started

Repeat while a condition holds

Repeat while a condition holds in a complete Rust program using the standard library.

Rust✓ Tested
RustStrings & Unicode

Replace a literal substring

Replace a literal substring in a complete Rust program using the standard library.

Rust✓ Tested
AngularServices & dependency injection

Replace a service implementation with useClass

Replace a service implementation with useClass with a standalone Angular component and explicit browser behavior.

Angular✓ Tested
AngularSignals & state

Replace a signal’s value explicitly

Replace a signal’s value explicitly with a standalone Angular component and explicit browser behavior.

Angular✓ Tested
Bash ScriptsFiles & reliability

Replace a text file with an atomic rename

Prepare new content beside the target before renaming it into place.

atomic write✓ Tested
jQueryInsertion & wrapping

Replace an element while preserving its position

jQuery: replaceWith swaps an entire node.

jQuery✓ Tested
AngularSignals & state

Replace an object signal immutably

Replace an object signal immutably with a standalone Angular component and explicit browser behavior.

Angular✓ Tested