Results for “item”
Small, practical examples. Search by task or narrow things down below.
Visit every item in a collection
C++: Print each element in the collection’s original order.
C++✓ Tested
Visit every item in a collection
C: Print each element in the collection’s original order.
C✓ Tested
Wrap a row of items
Allow CSS flex items to wrap when a row runs out of space.
CSS✓ Tested
Create a directory if needed
Ensure a directory exists before writing output.
New-Item✓ Tested
List files by extension
Enumerate regular files and return their names in order.
Get-ChildItem✓ Tested
Read the first collection element
Python: Access index zero only after establishing that the collection is nonempty.
Python✓ Tested
Read the first collection element
C#: Access index zero only after establishing that the collection is nonempty.
C#✓ Tested
Read the first collection element
Java: Access index zero only after establishing that the collection is nonempty.
Java✓ Tested
Read the first collection element
JavaScript: Access index zero only after establishing that the collection is nonempty.
JavaScript✓ Tested
Read the first collection element
TypeScript: Access index zero only after establishing that the collection is nonempty.
TypeScript✓ Tested
Read the first collection element
C++: Access index zero only after establishing that the collection is nonempty.
C++✓ Tested
Read the first collection element
C: Access index zero only after establishing that the collection is nonempty.
C✓ Tested