FIND YOUR NEXT FEW LINES

Results for “line”

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

132 snippets foundClear filters
TypeScriptGetting Started

Run your first program

TypeScript: Start with a complete program that prints one line. Follow the run instructions below.

TypeScript✓ Tested
C++Getting Started

Run your first program

C++: Start with a complete program that prints one line. Follow the run instructions below.

C++✓ Tested
CGetting Started

Run your first program

C: Start with a complete program that prints one line. Follow the run instructions below.

C✓ Tested
Linux CommandsText processing

Search for text in a file

Find matching lines with their line numbers, ignoring letter case and treating the pattern as literal text.

grep✓ Tested
CSSInteraction & themes

Show keyboard focus

Use a visible CSS outline when an input receives keyboard focus.

CSS✓ Tested
PythonStrings & dates

Split a string into words

Split text on whitespace, automatically treating repeated spaces, tabs, and line breaks as a single separator.

string✓ Tested
C++Strings

Split comma-separated text

Use getline with a delimiter to split simple C++ text.

C++✓ Tested
Arduino / CGetting Started

Turn on the LED with a serial command

Arduino / C: Wait for the character 1 in Serial Monitor before turning on the built-in LED.

Arduino / C✓ Tested
JavaScriptRegular expressions & URL encoding

Validate a whole ASCII identifier

JavaScript: Use an anchored expression without the multiline flag and reject a trailing line break explicitly.

JavaScript✓ Tested
TypeScriptRegular expressions & URL encoding

Validate a whole ASCII identifier

TypeScript: Use an anchored expression without the multiline flag and reject a trailing line break explicitly.

TypeScript✓ Tested
Bash ScriptsArguments & decisions

Validate the number of positional arguments

Bash Scripts: Use the argument count to enforce a simple command-line contract.

Bash Scripts✓ Tested
PowerShellFiles & paths

Write UTF-8 text to a file

Save a string without adding an extra newline.

Set-Content✓ Tested