Results for “read text”
Small, practical examples. Search by task or narrow things down below.
List regular files recursively in sorted order
C++: Collect relative paths before sorting because directory iteration order is unspecified.
C++✓ Tested
List the paths with unresolved merge conflicts
Git: The U diff filter identifies unmerged entries without parsing human-readable status output.
Git✓ Tested
Load a small properties configuration
Java: Use a Reader to make the configuration character encoding explicit.
Java✓ Tested
Look up a map key
Use find to read a C++ map without inserting a missing key.
C++✓ Tested
Map an input range to an output range
Scale an integer reading to a different interval.
map✓ Tested
Mark a self-contained article
HTML: Article identifies a standalone composition that can be read independently.
HTML✓ Tested
Measure a short delay with micros
Measure elapsed microseconds around a short operation.
micros✓ Tested
Merge object settings
Use object spread to apply JavaScript overrides to defaults.
JavaScript✓ Tested
Merge two sorted sequences
C++: Both inputs must use the same ordering before merge is called.
C++✓ Tested
Mount a local input directory with long syntax
Docker / Compose: Long mount syntax makes the bind type and read-only intent explicit.
Docker / Compose✓ Tested
Name a value that stays fixed
C++: Use a constant declaration or the language’s constant naming convention for a fixed limit.
C++✓ Tested
Narrow a union using typeof
Handle text and numeric values with separate branches.
union✓ Tested