FIND YOUR NEXT FEW LINES

Results for “if”

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

946 snippets foundClear filters
jQueryCollections & styling

Measure content, padding, and borders separately

jQuery: width, innerWidth, and outerWidth measure different parts of the box.

jQuery✓ Tested
C#JSON & binary formats

Measure the byte length of UTF-8 text

C#: Character count and encoded byte count can differ for non-ASCII text.

C#✓ Tested
SQLText cleanup & matching

Measure the length of ordinary text

SQL: Use the engine’s text-length function; this ASCII example has no trailing spaces.

SQL✓ Tested
SQL ServerText cleanup & matching

Measure the length of ordinary text

SQL Server: Use the engine’s text-length function; this ASCII example has no trailing spaces.

SQL Server✓ Tested
PostgresText cleanup & matching

Measure the length of ordinary text

Postgres: Use the engine’s text-length function; this ASCII example has no trailing spaces.

Postgres✓ Tested
SQLiteText cleanup & matching

Measure the length of ordinary text

SQLite: Use the engine’s text-length function; this ASCII example has no trailing spaces.

SQLite✓ Tested
PythonCollections

Merge two dictionaries

Combine two dictionaries into a new dictionary. When a key appears in both inputs, the value from the second dictionary wins.

dictionary✓ Tested
CSSPositioning & stacking

Move a box visually without changing its layout slot

CSS: Transforms change the painted geometry while leaving surrounding normal-flow layout unchanged.

CSS✓ Tested
HTMLAccessible structure

Move focus to a heading without adding a tab stop

HTML: A negative tabindex permits programmatic focus while keeping the heading out of ordinary sequential tab navigation.

HTML✓ Tested
HTMLImages & embedded documents

Name a meaningful image with alternative text

HTML: Alt supplies an accessible text alternative describing the image’s purpose.

HTML✓ Tested
SQLJoins & subqueries

Name an intermediate query with a CTE

Make a filtered result reusable within one statement.

CTE✓ Tested
HTMLAccessible structure

Name complementary content

HTML: Aside identifies supporting content related to the main document.

HTML✓ Tested