Similar Problems

Similar Problems not available

Letter Case Permutation - Leetcode Solution

Companies:

LeetCode:  Letter Case Permutation Leetcode Solution

Difficulty: Medium

Topics: string backtracking bit-manipulation  

Letter Case Permutation

Problem Statement

Given a string S, we can transform every letter individually to be lowercase or uppercase to create another string. Return a list of all possible strings we could create.

Examples:

Input: S = “r2q”

Output: [“r2q”, “R2q”, “r2Q”, “R2Q”].

Input: S = “678”

Output: [“678”]

Note:

  1. S will be a string with length between 1 and 12.
  2. S will consist only of letters or digits.

Letter Case Permutation Solution Code

1