Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

7
  • You will have to convert the strings either in upper or lower case while doing the comparison. What do you mean by "I don't want to change the lists to upper or lower case." Commented Nov 1, 2018 at 11:38
  • 1
    You don't want to convert anything to lower or upper case? Because that will be a problem. Or you just want the output to be in the same case as the input is in? Commented Nov 1, 2018 at 11:38
  • 1
    if you don't convert strings to uppercase or lowercase before you compare, you may end up trying compare 2^n strings before you can say it is not in the other list Commented Nov 1, 2018 at 11:40
  • @ozata for that approach, he'll still have to search all possible cases of the input string, which means, he'll still need to convert to some other cases. Commented Nov 1, 2018 at 11:45
  • because the output should be in the same case as the input is and these lists are stored in a DB. cost resources to change Commented Nov 1, 2018 at 11:48