Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 428a903

Browse files
refactor 1087
1 parent 4bc657b commit 428a903

File tree

1 file changed

+0
-24
lines changed

1 file changed

+0
-24
lines changed

src/main/java/com/fishercoder/solutions/_1087.java

Lines changed: 0 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -4,30 +4,6 @@
44
import java.util.Arrays;
55
import java.util.List;
66

7-
/**
8-
* 1087. Brace Expansion
9-
*
10-
* A string S represents a list of words.
11-
* Each letter in the word has 1 or more options. If there is one option, the letter is represented as is.
12-
* If there is more than one option, then curly braces delimit the options.
13-
* For example, "{a,b,c}" represents options ["a", "b", "c"].
14-
* For example, "{a,b,c}d{e,f}" represents the list ["ade", "adf", "bde", "bdf", "cde", "cdf"].
15-
*
16-
* Return all words that can be formed in this manner, in lexicographical order.
17-
*
18-
* Example 1:
19-
* Input: "{a,b}c{d,e}f"
20-
* Output: ["acdf","acef","bcdf","bcef"]
21-
*
22-
* Example 2:
23-
* Input: "abcd"
24-
* Output: ["abcd"]
25-
*
26-
* Note:
27-
* 1 <= S.length <= 50
28-
* There are no nested curly brackets.
29-
* All characters inside a pair of consecutive opening and ending curly brackets are different.
30-
* */
317
public class _1087 {
328
public static class Solution1 {
339
public String[] expand(String S) {

0 commit comments

Comments
 (0)