FIND YOUR NEXT FEW LINES

Results for “Input streams & redirection”

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

851 snippets foundClear filters
TypeScriptSafe data handling

Update an object with a readonly input

Create a changed copy while retaining the original.

readonly✓ Tested
CNumeric parsing & arithmetic

Validate a complete floating-point input

C: strtod exposes both the stopping position and range errors; reject nonfinite results when required.

C✓ Tested
HTMLForms

Validate an email input

Use browser constraint validation for a required HTML email field.

HTML✓ Tested
Linux CommandsStreams & byte tools

Count whitespace-separated words

Linux Commands: Use wc -w with standard input to omit the filename column.

Linux Commands✓ Tested
Linux CommandsStreams & byte tools

Save a stream while displaying it

Linux Commands: Use tee to write a copy of standard input to a file.

Linux Commands✓ Tested
HTMLInput constraints

Allow several selected options

HTML: A multiple select exposes each selected option as a value with the same control name.

HTML✓ Tested
Linux CommandsStreams & byte tools

Append a stream to a log file

Linux Commands: Use tee -a to preserve existing log contents.

Linux Commands✓ Tested
Linux CommandsStreams & byte tools

Count bytes in a file

Linux Commands: Use wc -c for byte length rather than Unicode character count.

Linux Commands✓ Tested
Linux CommandsStreams & byte tools

Encode and decode a file with Base64

Linux Commands: Use GNU base64 for text transport of bytes and --decode for the reverse operation.

Linux Commands✓ Tested
Linux CommandsStreams & byte tools

Inspect bytes as hexadecimal values

Linux Commands: Use od with explicit formatting and no address column.

Linux Commands✓ Tested
HTMLInput constraints

Limit typed text to a maximum length

HTML: Maxlength limits ordinary user editing without replacing server-side validation.

HTML✓ Tested
Arduino / CDigital input & output

Read a button with the internal pull-up

Treat a grounded input as a pressed button.

INPUT_PULLUP✓ Tested