Skip to content

Latest commit

 

History

History

generalized-abbreviation

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 

< Previous                  Next >

Write a function to generate the generalized abbreviations of a word. 

Note: The order of the output does not matter.

Example:

Input: "word"
Output:
["word", "1ord", "w1rd", "wo1d", "wor1", "2rd", "w2d", "wo2", "1o1d", "1or1", "w1r1", "1o2", "2r1", "3d", "w3", "4"]

 

Related Topics

[String] [Backtracking] [Bit Manipulation]

Similar Questions

  1. Subsets (Medium)
  2. Unique Word Abbreviation (Medium)
  3. Minimum Unique Word Abbreviation (Hard)