FIND YOUR NEXT FEW LINES

Results for “C++”

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

3000 snippets foundClear filters
AngularServices & dependency injection

Provide a configuration value with a token

Provide a configuration value with a token with a standalone Angular component and explicit browser behavior.

Angular✓ Tested
C#Types & reliable control flow

Provide a fallback for a nullable value

C#: The null-coalescing operator supplies a default only when the left side is null.

C#✓ Tested
CSSResponsive conditions & sizing

Provide a fallback for an unset custom property

CSS: The second var argument supplies a value when the custom property is unavailable.

CSS✓ Tested
HTMLGetting Started

Provide a list of selectable options

HTML: Learn how to provide a list of selectable options in a complete browser example.

HTML✓ Tested
ReactContext & shared state

Provide read-only application configuration

Provide read-only application configuration with a small React component and explicit browser behavior.

React✓ Tested
AngularLifecycle & observable data

Publish updated state through a BehaviorSubject

Publish updated state through a BehaviorSubject with a standalone Angular component and explicit browser behavior.

Angular✓ Tested
GitRemotes & collaboration

Pull without creating a merge commit

Update a branch only when its upstream can be fast-forwarded.

pull✓ Tested
GitRemotes & collaboration

Push a new branch and set its upstream

Connect a feature branch with its remote counterpart.

push✓ Tested
GitRemotes & additional checkouts

Push one selected release tag

Git: Naming a single tag avoids pushing every local tag unintentionally.

Git✓ Tested
Docker / ComposeCompose applications

Put an optional service behind a profile

Keep a utility service separate from a normal Compose startup.

Compose✓ Tested
GoConcurrency & cancellation

Queue values in a buffered channel

Queue values in a buffered channel using a complete Go program with explicit sample inputs.

Go✓ Tested
CBinary formats & structured parsing

Quote a CSV field and double embedded quotes

C: A quoted CSV field represents a quote character by repeating it.

C✓ Tested