FIND YOUR NEXT FEW LINES

Results for “duplicate”

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

58 snippets foundClear filters
PowerShellCollections & objects

Sort and deduplicate values

Produce an ordered list without duplicates.

Sort-Object✓ Tested
C++Collections

Sort and deduplicate values

Sort a C++ vector and erase adjacent duplicates.

C++✓ Tested
CDynamic memory & ownership

Allocate an independent copy of a C string

C: Include one extra byte for the terminating null character.

C✓ Tested
RustVectors & slices

Sort and remove repeated values

Sort and remove repeated values in a complete Rust program using the standard library.

Rust✓ Tested
C#Collections & data structures

Add a dictionary entry only if absent

C#: TryAdd reports a duplicate key without replacing its existing value.

C#✓ Tested
jQueryInsertion & wrapping

Clone markup without sharing its identity

jQuery: clone creates a separate node; change duplicated IDs before inserting.

jQuery✓ Tested
HTMLMetadata & document links

Declare a preferred canonical URL

HTML: A canonical link identifies the preferred public URL for duplicate representations of a document.

HTML✓ Tested
SQLSchema design & transactions

Enforce uniqueness with a dedicated index

SQL: A unique index rejects a duplicate combination independently of query plans.

SQL✓ Tested
SQL ServerSchema design & transactions

Enforce uniqueness with a dedicated index

SQL Server: A unique index rejects a duplicate combination independently of query plans.

SQL Server✓ Tested
PostgresSchema design & transactions

Enforce uniqueness with a dedicated index

Postgres: A unique index rejects a duplicate combination independently of query plans.

Postgres✓ Tested
SQLiteSchema design & transactions

Enforce uniqueness with a dedicated index

SQLite: A unique index rejects a duplicate combination independently of query plans.

SQLite✓ Tested
SQLBulk changes & set operations

Find rows shared by two query results

SQL: INTERSECT compares complete selected rows and removes duplicates.

SQL✓ Tested