LZ77 and LZ78 compression algorithms (used in gzip and PNG formats) scan streams of bytes looking for the longest sequences without duplicate characters. Efficiently finding the longest substring without repeating characters is a core sub-routine in stream compression logic.
Given a string `s`, find the length of the longest substring without repeating characters.
βΆ Run Code to test against examples Β· Submit to judge all 5 test cases