FIND YOUR NEXT FEW LINES

Results for “two”

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

173 snippets foundClear filters
TypeScriptRegular expressions & URL encoding

Reorder captured text in a replacement

TypeScript: Use numbered replacement groups to rearrange a known two-part name.

TypeScript✓ Tested
C++Text validation & parsing

Replace text using captured regex groups

C++: Numbered replacement groups can rearrange a known two-part name.

C++✓ Tested
HTMLNative disclosure & dialogs

Return a value from a dialog form

HTML: A form with method dialog closes its containing dialog without a network submission.

HTML✓ Tested
TypeScriptUtilities & async

Return typed data from an async function

Await a Promise and handle failures explicitly.

async✓ Tested
C++Sequence algorithms

Rotate a sequence around a selected position

C++: rotate places the element at the middle iterator first while preserving the two segment orders.

C++✓ Tested
Docker / ComposeGetting Started

Run a Compose service as a numeric user

Docker / Compose: Run a Compose service as a numeric user in a small Compose file.

Docker / Compose✓ Tested
jQueryEvents

Run an event handler once

Use jQuery one for a handler that removes itself after the first event.

jQuery✓ Tested
GitWorking tree & staging

See changed files

Show a concise working-tree status.

status✓ Tested
SQLSelect & filter

Select an inclusive range

Find rows with values between two endpoints.

BETWEEN✓ Tested
jQueryText & attributes

Set a form field value

Populate a labeled input with jQuery val.

jQuery✓ Tested
Docker / ComposeGetting Started

Set a service’s working directory

Docker / Compose: Set a service’s working directory in a small Compose file.

Docker / Compose✓ Tested
jQueryText & attributes

Set an element attribute

Update an HTML link using jQuery attr.

jQuery✓ Tested