FIND YOUR NEXT FEW LINES

Results for “flow”

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

73 snippets foundClear filters
Arduino / CData & storage

Average a fixed set of readings

Accumulate sample values without overflowing a 16-bit total.

array✓ Tested
CSmall algorithms & bit operations

Calculate a least common multiple using a GCD

C: Divide before multiplying to reduce the risk of intermediate overflow.

C✓ Tested
C++Numeric parsing & calculations

Calculate a two-dimensional vector length

C++: hypot avoids unnecessary intermediate overflow in the sum of squares.

C++✓ Tested
JavaPrecise numeric calculations

Calculate beyond the long integer range

Java: Use BigInteger when a fixed-width primitive type would overflow.

Java✓ Tested
C++Text validation & parsing

Check a literal suffix in C++17

C++: Check lengths before subtracting to avoid an unsigned underflow.

C++✓ Tested
GitRemotes & additional checkouts

Clone a local bare repository

Git: A local remote provides the same clone workflow without any network dependency.

Git✓ Tested
CNumeric parsing & arithmetic

Compute a two-dimensional vector length

C: hypot avoids unnecessary intermediate overflow compared with squaring both inputs directly.

C✓ Tested
CSSPositioning & stacking

Keep a tall section inside a local vertical scroller

CSS: A bounded height and overflow auto keep long content from stretching the surrounding page.

CSS✓ Tested
CSSPositioning & stacking

Move a box visually without changing its layout slot

CSS: Transforms change the painted geometry while leaving surrounding normal-flow layout unchanged.

CSS✓ Tested
CSSFlexbox alignment

Prevent an item from shrinking

CSS: Flex-shrink zero preserves a required size even when the container overflows.

CSS✓ Tested
CArray transformations

Sort an integer array with qsort

C: The comparator uses relational comparisons to avoid subtraction overflow.

C✓ Tested
CNumbers & memory

Swap two integers

Use a temporary value to swap C integers without arithmetic overflow.

C✓ Tested