FIND YOUR NEXT FEW LINES

Results for “two”

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

173 snippets foundClear filters
TypeScriptArray restructuring

Keep both matching and rejected values

TypeScript: Use two explicit outputs when a caller needs both sides of a classification.

TypeScript✓ Tested
Docker / ComposeGetting Started

Make a Compose service’s filesystem read-only

Docker / Compose: Make a Compose service’s filesystem read-only in a small Compose file.

Docker / Compose✓ Tested
jQueryEvents

Mirror input text

Update a result as the user types using a jQuery input event.

jQuery✓ Tested
PythonIteration & sequences

Pair corresponding list items

Python: Zip two equally sized sequences into pairs; strict mode rejects mismatched lengths on Python 3.10 or later.

Python✓ Tested
SQLRelationships & missing data

Pair employees with their managers

SQL: Alias a table twice to represent two different roles in one relationship.

SQL✓ Tested
SQL ServerRelationships & missing data

Pair employees with their managers

SQL Server: Alias a table twice to represent two different roles in one relationship.

SQL Server✓ Tested
PostgresRelationships & missing data

Pair employees with their managers

Postgres: Alias a table twice to represent two different roles in one relationship.

Postgres✓ Tested
SQLiteRelationships & missing data

Pair employees with their managers

SQLite: Alias a table twice to represent two different roles in one relationship.

SQLite✓ Tested
jQueryText & attributes

Read a data attribute

Read an element data attribute with jQuery data.

jQuery✓ Tested
jQueryTraversal & selection

Read checked options

Collect checked checkbox values with jQuery map and get.

jQuery✓ Tested
jQueryDOM & classes

Remove matching elements

Remove selected list items from the DOM with jQuery.

jQuery✓ Tested
JavaScriptRegular expressions & URL encoding

Reorder captured text in a replacement

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

JavaScript✓ Tested