FIND YOUR NEXT FEW LINES

Results for “JSON_VALUE”

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

718 snippets foundClear filters
C#Types & reliable control flow

Use a switch expression to classify a value

C#: Relational patterns express a small ordered range classification.

C#✓ Tested
Bash ScriptsParameter expansion

Use an alternate value only when a variable is nonempty

Bash Scripts: The colon-plus expansion returns its word only when the parameter has a nonempty value.

Bash Scripts✓ Tested
RustGetting Started

Use if to produce a value

Use if to produce a value in a complete Rust program using the standard library.

Rust✓ Tested
JavaScriptNumbers & numeric validation

Validate a finite numeric value without coercion

JavaScript: Number.isFinite rejects numeric strings as well as NaN and infinity.

JavaScript✓ Tested
TypeScriptNumbers & numeric validation

Validate a finite numeric value without coercion

TypeScript: Number.isFinite rejects numeric strings as well as NaN and infinity.

TypeScript✓ Tested
jQueryDeferred work & queues

Wait for several deferred values

jQuery: when resolves only after every supplied deferred has resolved.

jQuery✓ Tested
RustFunctions & data types

Wrap a value in a distinct type

Wrap a value in a distinct type in a complete Rust program using the standard library.

Rust✓ Tested
PythonJSON & CSV

Write a JSON file

Save a dictionary as readable, indented JSON while preserving Unicode characters.

json✓ Tested
PythonFunctions & error handling

Yield values on demand

Python: Use a generator to produce a sequence without storing all intermediate values.

Python✓ Tested
RustErrors & optional values

Add context to a parsing failure

Add context to a parsing failure in a complete Rust program using the standard library.

Rust✓ Tested
Arduino / CBinary values & packets

Assign a bit from a Boolean state

Arduino / C: bitWrite accepts a bit position and a zero or nonzero value.

Arduino / C✓ Tested
C++Containers & compound values

Build a minimum-priority queue

C++: Supply greater as the comparator because priority_queue defaults to the largest value first.

C++✓ Tested