cswork / OA打开练习工作台

WayfairOA #1

DFS Subsequences of a String (For MLE)

估计中等评测数据准备中,可先阅读题面

考点(AI 标注)拆分构造

A DFS probl

Example 1

Input:

s = "abc"

Output:

["a", "ab", "abc", "ac", "b", "bc", "c"]

Explanation: The function should return all possible subsequences of the input string "abc" sorted alphabetically, which are: ["a", "ab", "abc", "ac", "b", "bc", "c"].