Function ADS::moveToFront(std::string_view, std::string_view)

Function Documentation

inline std::vector<std::uint8_t> ADS::moveToFront(std::string_view s, std::string_view alphabet)

the places of the symbols of s in the list alphabet, each moved to the front after its use

Pre:

alphabet has distinct symbols, each symbol of s in it

Post:

inverseMoveToFront( result , alphabet ) == s (an audit)