Can T have characters repeating ?


  • 38
    H

    Can the String T have repeating characters - for instance "AA"? In that case should the minimum window contain two A's or does it suffice for it have a single A.


  • 18
    D

    Yes, T could have repeating chars. And minimum window should contain all of them. Here is an example test case from OJ:

    Input: "aa", "aa"

    Expected: "aa"


Log in to reply
 

Looks like your connection to LeetCode Discuss was lost, please wait while we try to reconnect.