File size: 534 Bytes
bff4ec7
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
# Coordinate Compression

## Description

Replace each integer by its rank among the distinct input values while preserving equality and order.

## Input

The verification-case input consists of an integer array `src` of length `n` and writable array `dest_map`.

## Output

The function produces the number of distinct values and the sorted distinct-value map in `dest_map`.

## Constraints

- All values and lengths fit in signed C `int` ranges.

## Source

Classical algorithmic problem reconstructed from the verified C artifact.