Results for “fixed”
Small, practical examples. Search by task or narrow things down below.
Format a timestamp with to_char
Produce a fixed numeric date string.
to_char✓ Tested
Format decimal output
Use fixed and setprecision to print two C++ decimal places.
C++✓ Tested
Give an item the remaining horizontal space
CSS: A growing flex item absorbs free space after fixed items have been sized.
CSS✓ Tested
Hash a file without reading it all at once
Python: Feed fixed-size binary chunks into SHA-256 for files larger than memory.
Python✓ Tested
Map an input range to an output range
Scale an integer reading to a different interval.
map✓ Tested
Pad a numeric label
Convert a number to text and pad it to a fixed width.
JavaScript✓ Tested
Preserve an aspect ratio
Reserve a 16:9 CSS box without a fixed height.
CSS✓ Tested
Print the final lines of a file
Linux Commands: Use tail -n for a fixed-size suffix of a log.
Linux Commands✓ Tested
Read a byte prefix
Linux Commands: Use GNU head -c for a fixed number of bytes, independent of line boundaries.
Linux Commands✓ Tested
Read a byte suffix
Linux Commands: Use GNU tail -c to extract a fixed-size ending.
Linux Commands✓ Tested
Read JSON into a hashtable
PowerShell: AsHashtable produces dictionary-style results for keys that are data rather than fixed property names.
PowerShell✓ Tested
Read named regex capture groups
JavaScript: Named groups make a fixed input format easier to inspect than numeric group positions.
JavaScript✓ Tested