FIND YOUR NEXT FEW LINES

Results for “work in progress”

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

540 snippets foundClear filters
GoDates & times

Parse a date with a Go layout

Parse a date with a Go layout using a complete Go program with explicit sample inputs.

Go✓ Tested
RustParsing & byte data

Parse a delimited integer record

Parse a delimited integer record in a complete Rust program using the standard library.

Rust✓ Tested
GoDates & times

Parse a duration string

Parse a duration string using a complete Go program with explicit sample inputs.

Go✓ Tested
RustParsing & byte data

Parse a hexadecimal integer

Parse a hexadecimal integer in a complete Rust program using the standard library.

Rust✓ Tested
Bash ScriptsFunctions & arguments

Parse a short option with getopts

Read a named option and handle invalid flags explicitly.

getopts✓ Tested
RustParsing & byte data

Parse a signed decimal integer

Parse a signed decimal integer in a complete Rust program using the standard library.

Rust✓ Tested
Bash ScriptsArguments & decisions

Parse a small set of long options

Bash Scripts: Use a loop and case statement to consume a value-bearing long option.

Bash Scripts✓ Tested
GoErrors & validation

Parse an email address syntax

Parse an email address syntax using a complete Go program with explicit sample inputs.

Go✓ Tested
Bash ScriptsText parsing & arithmetic

Parse digits with leading zeroes as decimal

Bash Scripts: The 10# prefix avoids Bash treating a leading zero as an octal notation.

Bash Scripts✓ Tested
RustIterators & transformations

Parse only valid integers

Parse only valid integers in a complete Rust program using the standard library.

Rust✓ Tested
RustIterators & transformations

Partition values into two collections

Partition values into two collections in a complete Rust program using the standard library.

Rust✓ Tested
Bash ScriptsInput streams & redirection

Pass a variable to standard input

Bash Scripts: A here-string supplies the expanded value followed by a newline.

Bash Scripts✓ Tested