Results for “Arduino / C”
Small, practical examples. Search by task or narrow things down below.
Parse a date without a time component
C#: DateOnly avoids attaching an irrelevant time or timezone to a calendar date.
C#✓ Tested
Parse a delimited integer record
Parse a delimited integer record in a complete Rust program using the standard library.
Rust✓ Tested
Parse a GUID without an exception
C#: TryParse reports malformed values with a boolean return.
C#✓ Tested
Parse a hexadecimal integer
PowerShell: Convert.ToInt32 accepts an explicit base for a validated hexadecimal string.
PowerShell✓ Tested
Parse a hexadecimal integer
Parse a hexadecimal integer in a complete Rust program using the standard library.
Rust✓ Tested
Parse a hexadecimal integer with from_chars
C++: An explicit radix controls digit interpretation without a locale dependency.
C++✓ Tested
Parse a signed decimal integer
Parse a signed decimal integer in a complete Rust program using the standard library.
Rust✓ Tested
Parse a typed command-line option
Python: Use argparse to validate and convert an integer option.
Python✓ Tested
Parse a UUID and inspect its version
Java: Use UUID.fromString for a standard UUID value.
Java✓ Tested
Parse an ISO calendar date
Python: Use date.fromisoformat and inspect the calendar components.
Python✓ Tested
Parse an unsigned hexadecimal integer
C: Use an explicit base and check both range and full consumption.
C✓ Tested
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