About this document
Shortest Lexicographic Weighted String by Abirami Sundaravel is a document available to read on EtoBox.
Each character has a weight defined by a formula. The function takes a target weight as input and returns the shortest string with that weight, or the lexicographically smallest if multiple strings have the same minimum length. It returns a string like "AABBC" for an input weight of 20.
- Author
- Abirami Sundaravel
- Language
- EN