FIND YOUR NEXT FEW LINES

Results for “test”

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

985 snippets foundClear filters
Arduino / CText & bounded buffers

Extract a section of an Arduino String

Arduino / C: substring includes the start index and excludes the end index.

Arduino / C✓ Tested
PythonStrings & dates

Extract numbers from text

Find all runs of ASCII digits in a string and convert the matches to integers.

regex✓ Tested
ReactCustom hooks

Extract reusable toggle behavior

Extract reusable toggle behavior with a small React component and explicit browser behavior.

React✓ Tested
Arduino / CBinary values & packets

Extract the low and high byte of a value

Arduino / C: lowByte and highByte expose the two bytes of a 16-bit value.

Arduino / C✓ Tested
jQueryAnimation completion

Fade a hidden element into view

jQuery: fadeIn shows a hidden element and calls its completion handler.

jQuery✓ Tested
jQueryAnimation completion

Fade an element out and hide it

jQuery: fadeOut sets display none after the opacity animation finishes.

jQuery✓ Tested
jQueryHTTP requests

Fetch a plain-text resource

jQuery: An explicit text data type keeps the response as a string.

jQuery✓ Tested
GitRemotes & collaboration

Fetch a remote branch

Refresh remote-tracking references before reviewing changes.

fetch✓ Tested
jQueryHTTP requests

Fetch and display JSON

jQuery: getJSON parses a successful JSON response.

jQuery✓ Tested
ReactLists & filtering

Filter a list by a search term

Filter a list by a search term with a small React component and explicit browser behavior.

React✓ Tested
PythonCollections

Filter a list with a condition

Build a new list containing only the values that satisfy a condition using a list comprehension.

list✓ Tested
jQueryTraversal & selection

Filter a selection

Reduce a jQuery selection to elements with a matching class.

jQuery✓ Tested