SecreC 2 language 2.9.0 (2026.10)
Language and standard library reference
Loading...
Searching...
No Matches
Functions
findSortingPermutation

Functions

template<domain D :shared3p >
D uint findSortingPermutation (D bool arr)
 

Detailed Description

Function for finding a stable sorting permutation.

Note
D - shared3p protection domain
Supported types - bool
performs two vectorized multiplications
Parameters
arr- a vector of supported type
Returns
returns a stable (in a sorting sense) permutation that moves false values to end
Leakage
None

Function Documentation

◆ findSortingPermutation()

template<domain D :shared3p >
D uint findSortingPermutation ( D bool  arr)