dynamic_programming.all_construct ================================= .. py:module:: dynamic_programming.all_construct .. autoapi-nested-parse:: Program to list all the ways a target string can be constructed from the given list of substrings Functions --------- .. autoapisummary:: dynamic_programming.all_construct.all_construct Module Contents --------------- .. py:function:: all_construct(target: str, word_bank: list[str] | None = None) -> list[list[str]] returns the list containing all the possible combinations a string(`target`) can be constructed from the given list of substrings(`word_bank`) >>> all_construct("hello", ["he", "l", "o"]) [['he', 'l', 'l', 'o']] >>> all_construct("purple",["purp","p","ur","le","purpl"]) [['purp', 'le'], ['p', 'ur', 'p', 'le']]