FIND YOUR NEXT FEW LINES

Results for “Precise numeric calculations”

Small, practical examples. Search by task or narrow things down below.

198 snippets foundClear filters
Arduino / CSerial protocols

Read an integer from serial input

Arduino / C: parseInt skips leading nonnumeric characters and reads the next integer.

Arduino / C✓ Tested
JavaScriptRegular expressions & URL encoding

Read named regex capture groups

JavaScript: Named groups make a fixed input format easier to inspect than numeric group positions.

JavaScript✓ Tested
TypeScriptRegular expressions & URL encoding

Read named regex capture groups

TypeScript: Named groups make a fixed input format easier to inspect than numeric group positions.

TypeScript✓ Tested
jQueryEvent control

Respond to the Enter key

jQuery: Use the event key rather than deprecated numeric key codes.

jQuery✓ Tested
CStructures & function interfaces

Return a status separately from a calculated result

C: An output pointer lets a function return success or failure independently of its numeric result.

C✓ Tested
Docker / ComposeBuild images

Run an image as a non-root user

Choose an unprivileged numeric identity for the default process.

Dockerfile✓ Tested
CSSType & reading flow

Set an explicit font weight

CSS: Numeric font weights express typographic emphasis independently of a specific font family.

CSS✓ Tested
Arduino / CData & storage

Set and inspect a bit flag

Store several boolean states in one byte.

bitSet✓ Tested
PythonCollections

Sort dictionaries by a value

Sort a list of dictionaries by a numeric field, leaving the original list unchanged.

sort✓ Tested
Linux CommandsSorting & joining records

Sort values in descending order

Linux Commands: Combine numeric sorting with reverse order.

Linux Commands✓ Tested
Linux CommandsSorting & joining records

Sort version-like labels naturally

Linux Commands: Use GNU version sort to compare embedded digit runs numerically.

Linux Commands✓ Tested
Linux CommandsStreams & byte tools

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