Results for “Numeric parsing & arithmetic”
Small, practical examples. Search by task or narrow things down below.
Set an explicit font weight
CSS: Numeric font weights express typographic emphasis independently of a specific font family.
CSS✓ Tested
Set and inspect a bit flag
Store several boolean states in one byte.
bitSet✓ Tested
Sort dictionaries by a value
Sort a list of dictionaries by a numeric field, leaving the original list unchanged.
sort✓ Tested
Sort values in descending order
Linux Commands: Combine numeric sorting with reverse order.
Linux Commands✓ Tested
Sort version-like labels naturally
Linux Commands: Use GNU version sort to compare embedded digit runs numerically.
Linux Commands✓ Tested
Split a file into fixed line-count pieces
Linux Commands: Use numeric suffixes for predictable filenames when splitting a large text file.
Linux Commands✓ Tested
Sum a collection
Calculate a total with Measure-Object.
Measure-Object✓ Tested
Sum typed values with reduce
Accumulate numeric array elements.
reduce✓ Tested
Swap two integers
Use a temporary value to swap C integers without arithmetic overflow.
C✓ Tested