Results for “UTF-8”
Small, practical examples. Search by task or narrow things down below.
Run your first program
C#: Start with a complete program that prints one line. Follow the run instructions below.
C#✓ Tested
Search a sorted array efficiently
C#: Array.BinarySearch requires an array sorted with the same comparison rules.
C#✓ Tested
Search for a literal LIKE wildcard
Postgres: Declare an escape character so a percent sign in the pattern is literal.
Postgres✓ Tested
Search text without case sensitivity
Match a pattern with PostgreSQL ILIKE.
ILIKE✓ Tested
Search the stream for a message marker
Arduino / C: find consumes input through a matching marker or until timeout.
Arduino / C✓ Tested
Select a response with switch
Arduino / C: Select a response with switch on an Uno with the Serial Monitor set to 9600 baud.
Arduino / C✓ Tested
Select the top row in each group with a tie-breaker
Postgres: Filter an outer query on ROW_NUMBER because window functions are not evaluated in WHERE.
Postgres✓ Tested
Select values in an inclusive range
Postgres: BETWEEN includes both endpoints of the range.
Postgres✓ Tested
Serialize an object to JSON
Serialize a small anonymous C# object with System.Text.Json.
C#✓ Tested
Set and inspect a bit flag
Store several boolean states in one byte.
bitSet✓ Tested
Show a group total beside each detail row
Postgres: A partitioned aggregate preserves detail rows instead of collapsing them with GROUP BY.
Postgres✓ Tested
Smooth a sequence with an exponential filter
Arduino / C: Blend each sample with the previous filtered value.
Arduino / C✓ Tested