Skip to content

Instantly share code, notes, and snippets.

@Desolve
Created January 30, 2020 15:28
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Desolve/1739bde8255945c392e5c87dec946573 to your computer and use it in GitHub Desktop.
Save Desolve/1739bde8255945c392e5c87dec946573 to your computer and use it in GitHub Desktop.
1332 Remove Palindromic Subsequences
class Solution:
def removePalindromeSub(self, s: str) -> int:
if not s: return 0
if s == s[::-1]: return 1
return 2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment