Leetcode Run Length Encoding Calculator