Results for “C”
Small, practical examples. Search by task or narrow things down below.
Name a value that stays fixed
C: Use a constant declaration or the language’s constant naming convention for a fixed limit.
C✓ Tested
Normalize a path without requiring it to exist
Linux Commands: Use GNU realpath -m and relative-to to normalize dot segments.
Linux Commands✓ Tested
Normalize an input with a transform
Normalize an input with a transform with a standalone Angular component and explicit browser behavior.
Angular✓ Tested
Number items while iterating
Python: Use enumerate to attach a one-based position without maintaining a separate counter.
Python✓ Tested
Observe shared ownership without extending its lifetime
C++: A weak_ptr can be locked while an owner exists and becomes expired after the last owner is released.
C++✓ Tested
Offer a downloadable text file
HTML: The download attribute supplies a filename for this same-document data URL.
HTML✓ Tested
Offer a retry after a failed attempt
Offer a retry after a failed attempt with a small React component and explicit browser behavior.
React✓ Tested
Offer an optional break inside a long label
HTML: Wbr supplies a potential line-break opportunity without inserting a visible hyphen.
HTML✓ Tested
Override an image’s entrypoint at runtime
Docker / Compose: An explicit entrypoint replaces the image entrypoint for this invocation.
Docker / Compose✓ Tested
Page an ordered result
Skip rows and fetch a bounded page.
OFFSET✓ Tested
Paint a gradient without an image file
CSS: Linear-gradient generates a CSS background image from color stops.
CSS✓ Tested
Parse a JSON string
Convert a JSON string into a Python dictionary and read values by key.
json✓ Tested