Ad
  • Custom User Avatar

    Our algorithms are the same, but a few neat hacks I added FYI:

    1. the "len" and "innerLen" variables cache the lengths of the inner and outer arrays, so they only be computed once
    2. the number 1 is truthy, so your if statement need not require the equals condition