FIND YOUR NEXT FEW LINES

Results for “at”

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

2630 snippets foundClear filters
JavaPrecise numeric calculations

Calculate beyond the long integer range

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

Java✓ Tested
C++Sequence algorithms

Calculate changes between successive readings

C++: adjacent_difference keeps the first value and then writes each difference from its predecessor.

C++✓ Tested
PythonIteration & sequences

Calculate cumulative totals

Python: Use accumulate to retain the running sum after each input.

Python✓ Tested
C++Sequence algorithms

Calculate cumulative totals

C++: partial_sum writes the sum of each input prefix to the output sequence.

C++✓ Tested
ReactState & reducers

Calculate derived state during rendering

Calculate derived state during rendering with a small React component and explicit browser behavior.

React✓ Tested
JavaScriptArray restructuring

Calculate differences between adjacent readings

JavaScript: Slice off the first value and compare each remaining value with its predecessor.

JavaScript✓ Tested
TypeScriptArray restructuring

Calculate differences between adjacent readings

TypeScript: Slice off the first value and compare each remaining value with its predecessor.

TypeScript✓ Tested
SQLReporting & grouped calculations

Calculate each group’s integer percentage of the total

SQL: Multiply before division and protect against a zero denominator.

SQL✓ Tested
SQL ServerReporting & grouped calculations

Calculate each group’s integer percentage of the total

SQL Server: Multiply before division and protect against a zero denominator.

SQL Server✓ Tested
PostgresReporting & grouped calculations

Calculate each group’s integer percentage of the total

Postgres: Multiply before division and protect against a zero denominator.

Postgres✓ Tested
SQLiteReporting & grouped calculations

Calculate each group’s integer percentage of the total

SQLite: Multiply before division and protect against a zero denominator.

SQLite✓ Tested
SQLReporting & grouped calculations

Calculate each group’s numeric spread

SQL: Subtract MIN from MAX to report the difference between extremes.

SQL✓ Tested