FIND YOUR NEXT FEW LINES

Results for “Dates & process utilities”

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

266 snippets foundClear filters
Bash ScriptsLoops & decisions

Sum a range of integers

Use an arithmetic loop without launching external processes.

arithmetic✓ Tested
C#Data & dates

Sum integer values

Sum a C# sequence using LINQ.

C#✓ Tested
JavaNumbers & dates

Sum integer values

Reduce a Java integer stream to its sum.

Java✓ Tested
GitInspecting the working tree

Summarize added and removed lines numerically

Git: Numstat provides tab-separated counts suitable for processing.

Git✓ Tested
Linux CommandsTransforming text

Translate ASCII lowercase letters to uppercase

Linux Commands: Use tr under a fixed locale for predictable ASCII character ranges.

Linux Commands✓ Tested
TypeScriptUtilities & async

Type an object update with Partial

Allow a caller to provide just the fields to change.

Partial✓ Tested
SQLBulk changes & set operations

Update rows selected by a related table

SQL: Use EXISTS to limit updates based on an independent eligibility table.

SQL✓ Tested
SQL ServerBulk changes & set operations

Update rows selected by a related table

SQL Server: Use EXISTS to limit updates based on an independent eligibility table.

SQL Server✓ Tested
PostgresBulk changes & set operations

Update rows selected by a related table

Postgres: Use EXISTS to limit updates based on an independent eligibility table.

Postgres✓ Tested
SQLiteBulk changes & set operations

Update rows selected by a related table

SQLite: Use EXISTS to limit updates based on an independent eligibility table.

SQLite✓ Tested
JavaNumbers & dates

Use an optional fallback

Use Optional.orElse to provide a default for a missing Java value.

Java✓ Tested
Linux CommandsArchive integrity & packaging

Verify a file against a checksum manifest

Linux Commands: Use sha256sum -c with a manifest obtained from a trusted source.

Linux Commands✓ Tested