FIND YOUR NEXT FEW LINES

Results for “UTF-8”

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

401 snippets foundClear filters
C#Getting Started

Require two conditions to be true

C#: Combine a lower and an upper bound to check whether a value is in range.

C#✓ Tested
PostgresGetting Started

Require two filtering conditions

Postgres: Combine category and quantity conditions with AND.

Postgres✓ Tested
C#Asynchronous work & URI handling

Resolve a relative URI against a base

C#: Use a base URI ending in a slash when the final path component represents a directory.

C#✓ Tested
PostgresSubqueries & ranked selection

Return all rows tied for the maximum in a group

Postgres: An equality comparison with a grouped maximum retains ties rather than choosing one arbitrary row.

Postgres✓ Tested
PostgresRows & writes

Return an inserted row

Read generated data directly from INSERT.

RETURNING✓ Tested
C#Types & reliable control flow

Return multiple named values from a method

C#: Named value tuples give lightweight field names without a separate class.

C#✓ Tested
PostgresReporting & grouped calculations

Return zero for a sum over no rows

Postgres: SUM produces NULL for an empty input; COALESCE supplies the desired reporting default.

Postgres✓ Tested
Arduino / CGetting Started

Reuse an LED action with a function

Arduino / C: Put a short LED sequence in a named function and call it twice.

Arduino / C✓ Tested
C#Dates & precise numbers

Round a decimal using an explicit midpoint rule

C#: Use decimal literals for decimal arithmetic and choose the midpoint rounding behavior.

C#✓ Tested
PostgresDates & series

Round a timestamp down to its month

Group dates by a calendar boundary.

date_trunc✓ Tested
PostgresGetting Started

Run a first SELECT query

Postgres: Return a literal value without creating a table.

Postgres✓ Tested
Arduino / CGetting Started

Run a first sketch and read serial output

Arduino / C: Run a first sketch and read serial output on an Uno with the Serial Monitor set to 9600 baud.

Arduino / C✓ Tested