Given a string, how would you write a function that returns each character with its consecutive count, like aaaaffffggaa -> a4f4g2a2?
Return one character-count pair for each maximal consecutive run, preserving the original order. The function should return an empty string for empty input and treat characters as case-sensitive.
def encode_runs(s): accepts a string and returns a string.
def encode_runs(s):