Results for “by”
Small, practical examples. Search by task or narrow things down below.
Inspect a byte without consuming it
Arduino / C: peek leaves the next byte available for a later read.
Arduino / C✓ Tested
Inspect bytes as hexadecimal values
Linux Commands: Use od with explicit formatting and no address column.
Linux Commands✓ Tested
Join lines from two files side by side
Linux Commands: Use paste to pair lines by position with a chosen separator.
Linux Commands✓ Tested
Join two sorted files by a shared key
Linux Commands: Use join for sorted, simple delimiter-separated records with one row per key.
Linux Commands✓ Tested
Keep caller data unchanged by passing a structure by value
C: A value parameter is a copy of the original structure.
C✓ Tested
Keep loop state by avoiding a pipeline subshell
Bash Scripts: Redirect input into a while loop so updates to a counter remain in the current shell.
Bash Scripts✓ Tested
Limit the bytes read from a stream
Limit the bytes read from a stream using a complete Go program with explicit sample inputs.
Go✓ Tested
List files by extension
Enumerate regular files and return their names in order.
Get-ChildItem✓ Tested
List files changed by the current commit
Git: diff-tree exposes the paths changed between a commit and its parent.
Git✓ Tested
List files tracked by Git
Git: ls-files reads the index instead of listing every file in the working directory.
Git✓ Tested
Make a script executable by its owner
Linux Commands: Add the owner execute bit without replacing all permission bits.
Linux Commands✓ Tested
Measure the byte length of UTF-8 text
C#: Character count and encoded byte count can differ for non-ASCII text.
C#✓ Tested