Results for “read only”
Small, practical examples. Search by task or narrow things down below.
Increment a stored value in the database
SQLite: An in-database arithmetic update avoids a separate application read-modify-write step.
SQLite✓ Tested
Increment an atomic counter
Increment an atomic counter using a complete Go program with explicit sample inputs.
Go✓ Tested
Insert a value while preserving sorted order
Python: Use insort on an already sorted list; insertion still shifts later list elements.
Python✓ Tested
Insert and retrieve a map value
Insert and retrieve a map value in a complete Rust program using the standard library.
Rust✓ Tested
Inspect a byte without consuming it
Arduino / C: peek leaves the next byte available for a later read.
Arduino / C✓ Tested
Inspect a parsed URI
C#: Use Uri properties instead of splitting URL strings manually.
C#✓ Tested
Inspect a path’s filename and extension
Inspect a path’s filename and extension in a complete Rust program using the standard library.
Rust✓ Tested
Inspect a revision with detached HEAD
Git: Detached mode is useful for inspection; create a branch before keeping new work.
Git✓ Tested
Inspect a substring without allocating a copy
C++: A string_view refers to existing storage and must not outlive that storage.
C++✓ Tested
Inspect a typed conversion error
Inspect a typed conversion error using a complete Go program with explicit sample inputs.
Go✓ Tested
Inspect a value with a type switch
Inspect a value with a type switch using a complete Go program with explicit sample inputs.
Go✓ Tested
Inspect a value’s type
Inspect a value’s type using a complete Go program with explicit sample inputs.
Go✓ Tested