Results for “all”
Small, practical examples. Search by task or narrow things down below.
Create an index matching filter and ordering columns
Postgres: Place the equality-filter column before the ordering column in this composite index.
Postgres✓ Tested
Create an index matching filter and ordering columns
SQLite: Place the equality-filter column before the ordering column in this composite index.
SQLite✓ Tested
Create and clean up a temporary file
Java: Create a unique file and remove it in finally even when the operation fails.
Java✓ Tested
Create nested directories
Use C++17 filesystem to create a directory tree.
C++✓ Tested
Create nested folders
Create a folder and any missing parent folders in one call. Running the code again is safe when the folder already exists.
directory✓ Tested
Customize a renderer through a function prop
Customize a renderer through a function prop with a small React component and explicit browser behavior.
React✓ Tested
Declare a fixed configuration value
Bash Scripts: Declare a fixed configuration value with a small standalone Bash program.
Bash Scripts✓ Tested
Declare a named volume in Compose
Mount persistent storage at a service path.
Compose✓ Tested
Declare an indexing preference for a draft page
HTML: A robots meta element can request noindex while allowing link following.
HTML✓ Tested
Decode a 16-bit big-endian integer
C: Promote bytes to an unsigned integer type before combining shifted values.
C✓ Tested
Decode a validated pair of hexadecimal digits
C: Convert each nibble and reject a nonhexadecimal character before combining them.
C✓ Tested
Decode hexadecimal bytes
C#: FromHexString and ToHexString handle binary data without manually parsing pairs of characters.
C#✓ Tested