Skip to content

Instantly share code, notes, and snippets.

@mangafas
Created March 29, 2017 12:11
Show Gist options
  • Save mangafas/01606032cd1c0f9b03c50c0ef01d8231 to your computer and use it in GitHub Desktop.
Save mangafas/01606032cd1c0f9b03c50c0ef01d8231 to your computer and use it in GitHub Desktop.
x = input()
t = []
l = 0
for c in x:
l += 1
if l >= len(x):
break
if c + x[l] not in t:
t.append(c + x[l])
for o in t:
print(o + ": " + str(x.count(o)))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment