Problem:


Counting Characters

  Write a program which counts and reports the number of each alphabetical letter. Ignore the case of characters.

Input

  A sentence in English is given in several lines.

Output

  Prints the number of alphabetical letters in the following format:

a : The number of 'a'
b : The number of 'b'
c : The number of 'c'
  .
  .
z : The number of 'z'

Constraints

The number of characters in the sentence < 1200

Sample Input

This is a pen.

Sample Output

a : 1
b : 0
c : 0
d : 0
e : 1
f : 0
g : 0
h : 1
i : 2
j : 0
k : 0
l : 0
m : 0
n : 1
o : 0
p : 1
q : 0
r : 0
s : 2
t : 1
u : 0
v : 0
w : 0
x : 0
y : 0
z : 0



Sample input:
This is a pen.


Sample output:
a : 1
b : 0
c : 0
d : 0
e : 1
f : 0
g : 0
h : 1
i : 2
j : 0
k : 0
l : 0
m : 0
n : 1
o : 0
p : 1
q : 0
r : 0
s : 2
t : 1
u : 0
v : 0
w : 0
x : 0
y : 0
z : 0

Submission status: Accepted

Solution code:
from string import ascii_lowercase, ascii_uppercase
s = open(0).read()
ans = [0]*26
for c in s:
    i = ascii_lowercase.find(c)
    if i > -1:
        ans[i]+=1
    i = ascii_uppercase.find(c)
    if i > -1:
        ans[i]+=1

for c, t in zip(ascii_lowercase,ans):
    print("%s : %d"%(c,t))

Submission status: Accepted

Solution code:
a = []
try:
    while True:
        a.append(input())
except EOFError:
    pass

for i in range(len(a)):
    a[i] = a[i].lower()

b=" ".join(a)

for j in "abcdefghijklmnopqrstuvwxyz":
    print(j,":",b.count(j))

Submission status: Accepted

Solution code:
data = ""
data_1 = [chr(ord('a') + i) for i in range(26)]
while True:
    try:
        data += input().lower()
    except EOFError:
        break
for i in data_1:
    j = data.count(i)
    print(f'{i} : {j}')

Submission status: Accepted

Solution code:
cnt = [0 for i in range (26)]
alphabet = 'abcdefghijklmnopqrstuvwxyz'
str = open(0).read()
for x in str:
    for k in range(len(alphabet)):
        if x == alphabet[k] or x == alphabet[k].upper():
            cnt[k] = cnt[k] + 1
            break

for i in range(26):
    print(alphabet[i], ':', cnt[i])

Submission status: Accepted

Solution code:
import sys
texts=sys.stdin.read()
texts=texts.lower()
cnt=[0]*26

letters=list('abcdefghijklmnopqrstuvwxyz')
for x in texts:
    i=0
    for y in letters:
        if x==y:
            cnt[i]+=1
        i+=1
for i in range(26):
    print(letters[i]+" : "+str(cnt[i]))

Submission status: Accepted

Solution code:
import sys
cnts={}
for line in sys.stdin:
	for c in list(line.lower()): cnts[c]=cnts.get(c,0)+1

for c in range(ord('a'),ord('z')+1): print(chr(c),':',cnts.get(chr(c),0))

Submission status: Accepted

Solution code:
alpha = "abcdefghijklmnopqrstuvwxyz"
A = [0]*26

while True :
    try :
        n = input()
        
        for i in range(len(n)) :
            if n[i] in alpha or n[i].lower() in alpha :
                A[alpha.index(n[i].lower())] += 1
    except :
        break
    
for j in range(len(A)) :
    print(alpha[j], ":", A[j])

Submission status: Accepted

Solution code:
import re,sys
al=[chr(ord('a')+i) for i in range(26)]
s=sys.stdin.read().lower()
for i in range(26):
    cnt=len(re.findall(al[i],s))
    print("{} : {}".format(al[i],cnt))

Submission status: Accepted

Solution code:
import sys
texts=sys.stdin.read()
texts=texts.lower()
cnt=[0]*26

letters=list('abcdefghijklmnopqrstuvwxyz')
for x in texts:
    i=0
    for y in letters:
        if x==y:
            cnt[i]+=1
        i+=1
for i in range(26):
    print(letters[i]+" : "+str(cnt[i]))

Submission status: Accepted

Solution code:
s=[0]*26
try:
    while True:
        n=str(input())
        n=n.lower()
        #print(n)
        for i in range(len(n)):
            if 97<=ord(n[i])<=122:
                s[ord(n[i])-97]+=1
except EOFError:pass
for j in range(26):
    print(chr(j+97),':',s[j])

Submission status: Accepted

Solution code:
import sys
import string

sentence = sys.stdin.read().lower()
for c in string.ascii_lowercase:
    print('{} : {}'.format(c, sentence.count(c)))

Submission status: Accepted

Solution code:
count = [0 for i in range(26)]
while True:
    try:
        s = input()
    except:
        break
    for i in range(len(s)):
        m = ord(s[i]) - ord("a")
        if(m >= 0 and m <= 26):
            count[m] += 1
        m = ord(s[i]) - ord("A")
        if(m >= 0 and m <= 26):
            count[m] += 1
for i in range(26):
    print(chr(i + ord("a")), ":", count[i])

Submission status: Accepted

Solution code:
import sys
b=sys.stdin.read().lower()
for i in range(97,123):
    print(chr(i),':',(b.count(chr(i))))

Submission status: Accepted

Solution code:
import sys
a=sys.stdin.read().lower()
for i in range (ord("a"),ord("z")+1):
    print(chr(i), ":", a.count(chr(i)))

Submission status: Accepted

Solution code:
n = open(0)
n = n.read()
l1 = "abcdefghijklmnopqrstuvwxyz"
l2 = [0]*26

for i in n:
   for j in range(len(l1)):
      if i == l1[j] or i == l1[j].upper():
         l2[j] += 1

for i in range(len(l1)):
   print(l1[i], ":", l2[i])

Submission status: Accepted

Solution code:

import sys
a=[]
for i in sys.stdin.readlines():
    a.append(i.rstrip())
    
b=''.join(a)
x=str.lower(b)

for i in "abcdefghijklmnopqrstuvwxyz":
    countable=x.count(i)
    print(f'{i} : {countable}')

Submission status: Accepted

Solution code:
alphabet = [0 for i in range(26)]

while True:
    try:
        word = input()
    except:
        break
    word_s=str.lower(word)
    for i in range(len(word_s)):
        a = ord(word_s[i])-ord('a')
        if (a >= 0 and a < 26):
            alphabet[a]+=1
        
for i in range(26):
    print(chr(i+ord('a')),":",alphabet[i])

Submission status: Accepted

Solution code:
# coding: utf-8
# Your code here!
s=""
while True:
    try:
        s+=input()
    except:
        break
s=s.lower()
for i in range(ord("a"),ord("z")+1):
    print(chr(i)+" :",s.count(chr(i)))

Submission status: Accepted

Solution code:
count_al = list(0 for i in range(26))
while True :
    try :
        a = str(input())
        b = a.lower()
        for i in range(len(b)) :
            c = ord(b[i])
            if c > 96 and c < 123 :
                count_al[c - 97] += 1
    except EOFError :
        break
    
for i in range(97, 123) :
    print(chr(i), ":", count_al[i-97])

Submission status: Accepted

Solution code:
import string
text = ''
while True:
    try:
        text += input().lower()
    except EOFError:
        break
for chr in string.ascii_lowercase:
    print('{} : {}'.format(chr, text.count(chr)))

Submission status: Accepted

Solution code:
from string import ascii_lowercase as asc
import sys
sen = sys.stdin.read()
sent = list(sen.lower())
for i in asc:
	print(i,":",sent.count(i))

Submission status: Accepted

Solution code:
import sys
a=[]
for i in sys.stdin.readlines():
    a.append(i.rstrip())

b=''.join(a)
x=str.lower(b)

for i in "abcdefghijklmnopqrstuvwxyz":
    countable=x.count(i)
    print(f'{i} : {countable}')

Submission status: Accepted

Solution code:
s = ''
while True:
  try:
    s += input().lower()
  except EOFError:
    break
for i in range(97, 123):
  print(chr(i)+' : '+str(s.count(chr(i))))

Submission status: Accepted

Solution code:
import collections


s = ''
while True:
    try:
        s += input().lower()
    except EOFError:
        break
c = collections.Counter(s)
for i in range(97, 123):
    print("{} : {}".format(chr(i), c[chr(i)]))

Submission status: Accepted

Solution code:
English_sentence=''
try:
    while True:
        line=input()
        if line=='':
            break
        English_sentence+=line
except EOFError:
	pass
lowercase=['a','b','c','d','e','f','g','h','i','j','k','l','m','n','o','p','q','r','s','t','u','v','w','x','y','z']
uppercase=['A','B','C','D','E','F','G','H','I','J','K','L','M','N','O','P','Q','R','S','T','U','V','W','X','Y','Z']
number=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]
for _ in range(26):
    for _2 in English_sentence:
        if _2==lowercase[_] or _2==uppercase[_]:
            number[_]+=1
for ans in range(26):
    print("{0} : {1}".format(lowercase[ans],number[ans]))

Submission status: Accepted

Solution code:
import sys
a = [0]*26
s = sys.stdin.read().lower()
for i in map(chr, range(ord('a'), ord('z')+1)):
    print(i, ':', s.count(i))

Submission status: Accepted

Solution code:
a = ""
while True:
    try:
        a += input().lower()
    except:
        break
for i in range(ord("a"), ord("z")+1):
    print("{} : {}".format(chr(i), a.count(chr(i))))

Submission status: Accepted

Solution code:
x=[]
while True:
    try:
        z=list(input())
    except EOFError:
        break
    x=x+z
import collections
c=collections.Counter(x)
import string
a=string.ascii_letters
for i in range(26):
    print(a[i],":",(c[a[0+i]]+c[a[26+i]]))

Submission status: Accepted

Solution code:
import sys
s = sys.stdin.read()
s = s.lower()
alp = "qazxswedcvfrtgbnhyujmkiolp"
alp = sorted(alp)
for c in alp:
  print('{} : {}'.format(c,s.count(c)))

Submission status: Accepted

Solution code:
import sys
txt = sys.stdin.read().lower()
for i in "abcdefghijklmnopqrstuvwxyz":
    print(i,":",txt.count(i))

Submission status: Accepted

Solution code:
import sys
s = sys.stdin.read().lower()
a = {chr(i): 0 for i in range(ord('a'), ord('z')+1)}
for i in s:
    if ord(i) in range(ord('a'), ord('z')+1):
        a[i] += 1
[print(f'{k} : {v}') for k, v in a.items()]

Submission status: Accepted

Solution code:
import sys
s = sys.stdin.read().lower()

al = [chr(ord("a") + i) for i in range(26)]

for a in al:
  c = 0
  c = s.count(a)
  print('{0} : {1}'.format(a, c))

Submission status: Accepted

Solution code:
import sys
s=sys.stdin.read().lower()
for i in range(97,123):
 print(chr(i),":",s.count(chr(i)))

Submission status: Accepted

Solution code:
import sys

BIG_NUM = 2000000000
MOD = 1000000007
EPS = 0.000000001


table = [0]*26

letters = "abcdefghijklmnopqrstuvwxyz"
input_str = sys.stdin.read()

for A in input_str:
    index = 0
    for B in letters:
        if A == B or A == B.upper():
            table[index] += 1
            
        index += 1

for i in range(len(letters)):
    print("%s : %d"%(letters[i],table[i]))

Submission status: Accepted

Solution code:
c=[]
S=[]
lst=[]
import string
a=string.ascii_letters
import collections
try:
    while True:
        lst=lst+list(input())
        
        #S += collections.Counter(c)
except EOFError:
    pass
c = collections.Counter(lst)

for i in range(26):
    print(a[i]+" : "+str(c[a[0+i]]+c[a[26+i]]))

Submission status: Accepted

Solution code:
a=input()
while True:
    try:
        a+=(str(input()))
    except EOFError:
        break
b=str.lower(a)
for i in range(ord('a'),ord('z')+1):
    count=0
    print(chr(i),':',end=' ')
    for j in range(len(b)):
        c=ord(b[j])
        if i==c:
            count+=1
    print(count)

Submission status: Accepted

Solution code:
import sys
alphabet = "abcdefghijklmnopqrstuvwxyz"

string = sys.stdin.read()

for s in alphabet:
    print(s+" : "+str(string.lower().count(s)))

Submission status: Accepted

Solution code:
alphabet=dict.fromkeys("abcdefghijklmnopqrstuvwxyz",0)
t=list(alphabet)
while True:
    try:
        N = input()
    except:
        break
    N=N.lower()
    z = list(N)
    if N=='':
        break
    for i in range(len(z)):
        for j in range(len(t)):
            if z[i]==t[j]:
                alphabet[t[j]]+=1
for key, value in alphabet.items():
    print(key, ':', value)

Submission status: Accepted

Solution code:
#
# 8c
#
import sys


def main():
    A = "abcdefghijklmnopqrstuvwxyz"
    r = [0 for _ in range(26)]
    S = sys.stdin.read()

    for i in range(len(S)):
        for j in range(len(A)):
            if S[i].lower() == A[j]:
                r[j] += 1
                break
    for i in range(26):
        print(f"{A[i]} : {r[i]}")


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
import sys
line = sys.stdin.read().lower()
al_dict = {}

for al in [chr(i) for i in range(ord('a'), ord('z')+1)]:
    al_dict[al] = 0
    
for al in line:
    if al_dict.get(al) != None:
        al_dict[al] += 1

for al in al_dict:
    print('{} : {}'.format(al, al_dict[al]))

Submission status: Accepted

Solution code:
import sys
x=sys.stdin.read().lower()
for i in range(97,123):
    print(chr(i),':',x.count(chr(i)))

Submission status: Accepted

Solution code:
import collections

n = []

while True:
   try:
       N = input()
   
   except EOFError:
       break
   
   N = N.lower() 
    
   N.replace('', ' ')
   
   n.extend(N)
   
c = collections.Counter(n)

for i in range(97, 97+26):
        print("%s : %d" % (chr(i),c[chr(i)]) )

Submission status: Accepted

Solution code:
import sys


table = [0]*26

letters = "abcdefghijklmnopqrstuvwxyz"
input_str = sys.stdin.read()

for A in input_str:
    ind = 0
    for B in letters:
        if A == B or A == B.upper():
            table[ind] += 1
            break
        ind += 1

for i in range(len(letters)):
    print("%s : %d"%(letters[i],table[i]))

Submission status: Accepted

Solution code:
s1 = ''
try:
    while True:
        t = input()
        if t == '':
            break
        s1 += t
except EOFError:
    pass

n = [0] * 26
s = s1.lower()
for i in range(len(s)):
    j = ord(s[i]) - 97
    if j >= 0 and j < 26:
        n[j] += 1
for i in range(26):
    print('%s : %d' %(chr(i + 97),n[i]))

Submission status: Accepted

Solution code:
import re
import sys
s = re.findall('[a-z]', sys.stdin.read().lower())
letters = 'abcdefghijklmnopqrstuvwxyz'
cnt = [0]*26
for i in s:
    point = 0
    for j in letters:
        if i == j:
            cnt[point] += 1
            break
        point += 1
for i in range(26):
    print('%s : %d'%(letters[i], cnt[i]))

Submission status: Accepted

Solution code:
count_char = list(0 for i in range(26))
while True :
    try :
        str_org = str(input())
        str_org = str_org.lower()
        for i in range(len(str_org)) :
            num_org = ord(str_org[i])
            if num_org > 96 and num_org < 123 :
                count_char[num_org - 97] += 1
    except EOFError :
        break
for i in range(97, 123) :
    print(chr(i), ":", count_char[i-97])

Submission status: Accepted

Solution code:
import sys
N=sys.stdin.read()
K=len(N)
N=N.lower()
U=[0]*26
list="abcdefghijklmnopqrstuvwxyz"
for i in range(K):
  for u in range(26):
    if N[i]==list[u]:
      U[u]+=1
for h in range(26):
    print(f"{list[h]} : {U[h]}")

Submission status: Accepted

Solution code:
letters = {
    "a": 0,
    "b": 0,
    "c": 0,
    "d": 0,
    "e": 0,
    "f": 0,
    "g": 0,
    "h": 0,
    "i": 0,
    "j": 0,
    "k": 0,
    "l": 0,
    "m": 0,
    "n": 0,
    "o": 0,
    "p": 0,
    "q": 0,
    "r": 0,
    "s": 0,
    "t": 0,
    "u": 0,
    "v": 0,
    "w": 0,
    "x": 0,
    "y": 0,
    "z": 0,
}

while True:
    try:
        l = list(input())
        if len(l) == 0:
            break
        for c in l:
            cl = c.lower()
            if cl in letters:
                letters[cl] += 1
    except EOFError:
        break

ks = list(letters.keys())
vs = list(letters.values())

for i in range(len(ks)):
    print("%s : %s" % (ks[i], vs[i]))

Submission status: Accepted

Solution code:
tmp = "abcdefghijklmnopqrstuvwxyz"
alph = list(tmp)
alphcount = [0]*26

while True:
    try:
        letter = input()
        letterarray = list(letter.lower())
        # print(letterarray)

    except:
        break

    for x in letterarray:
        for i in range(26) :
            if (x == alph[i]):
                alphcount[i] += 1

            else :
                continue

for i in range(26):
    print(str(alph[i])+" : "+str(alphcount[i]))

Submission status: Accepted

Solution code:
import sys
buff=sys.stdin.read()
buff=buff.lower()
alp="abcdefghijklmnopqrstuvwxyz"
for i in range(len(alp)):
  print(alp[i],':',buff.count(alp[i]))

Submission status: Accepted

Solution code:
al = 'abcdefghijklmnopqrstuvwxyz'
text = ''

while True:
    try:
        text += input().lower()
    except EOFError:
        break

for i in al:
    print('{} : {}'.format(i, text.count(i)))

Submission status: Accepted

Solution code:
word = []
counter = [0]*26
alphabed = list('abcdefghijklmnopqrstuvwxyz')
try:
  while True:
    input_word = list(input().lower())
    if word == '':
      break
    for i in range(len(input_word)):
      word.append(input_word[i])
except EOFError:
  pass
for i in range(len(word)):
  for j in range(26):
    if word[i] == alphabed[j]:
      counter[j] += 1
for i in range(26):
  print('%s : %d'%(alphabed[i], counter[i]))

Submission status: Accepted

Solution code:
alp = 'abcdefghijklmnopqrstuvwxyz'
text = ''
while True:
    try:
        text += input().lower()
    except:
        break

for chr in alp:
    print(chr + ' : ' + str(text.count(chr)))

Submission status: Accepted

Solution code:
import sys

BIG_NUM = 2000000000
MOD = 1000000007
EPS = 0.000000001


table = [0]*26

letters = "abcdefghijklmnopqrstuvwxyz"
input_str = sys.stdin.read()

for A in input_str:
    index = 0
    for B in letters:
        if A == B or A == B.upper():
            table[index] += 1
            break
        index += 1

for i in range(len(letters)):
    print("%s : %d"%(letters[i],table[i]))

Submission status: Accepted

Solution code:
x_input = ''
try:
    while True:
        x = input()
        x_input = x + x_input
        if x == '':
            break
except EOFError:
    pass

for i in range(97, 123):
    x_low = x_input.lower()

    print(chr(i), ':', str(x_low.count(chr(i))))

Submission status: Accepted

Solution code:
list=[]

try:
    while True:
        list.append(input())
except EOFError:
    pass

for i in range(len(list)):
    list[i]=list[i].lower()
w=''.join(list)

for c in 'abcdefghijklmnopqrstuvwxyz':
    print(c,':',w.count(c))

Submission status: Accepted

Solution code:
import string
bb=""
while True:
    try:
        a=str(input())
        b=a.lower()
        bb=bb+b
    except EOFError:
        break
for i in string.ascii_lowercase:
            #for o in range(26):
    c=bb.count(i)
    print("{} : {}".format(i,c))

Submission status: Accepted

Solution code:
list=[]
alphabet = dict.fromkeys("\
abcdefghijklmnopqrstuvwxyz",0)

while True:
    try:
        str=input()
    except EOFError:
        break
        continue
    if str=='':
        break
    new=str.lower()
    list.append(new)

s = "".join(list)
for c in "abcdefghijklmnopqrstuvwxyz":
    countable=s.count(c)
    print(c,":",countable)

Submission status: Accepted

Solution code:
s=""
while True:
    try:
        s += input().lower()
    except:
        break
for c in 'abcdefghijklmnopqrstuvwxyz':
    print(c,':',s.count(c))

Submission status: Accepted

Solution code:
# 8_D
alp=["a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z"]
my_dic={'a':0,'b':0,'c':0,'d':0,'e':0,'f':0,'g':0,'h':0,'i':0,'j':0,'k':0,'l':0,'m':0,'n':0
        ,'o':0,'p':0,'q':0,'r':0,'s':0,'t':0,'u':0,'v':0,'w':0,'x':0,'y':0,'z':0}
while(True):
    try:
        var=input()
    except:
        break
    for i in alp:
        s=my_dic[i]
        s+=var.lower().count(i)
        my_dic[i]=s
    
for i in alp:
    print(i+" : "+str(my_dic[i]))

Submission status: Accepted

Solution code:
A=[]
while True:
    try:
        A.append(input())
    except EOFError:
        break


a=list("abcdefghijklmnopqrstuvwxyz")
counter=[0 for i in range(len(a))]
for j in A:
    for i in range(len(a)):
        counter[i]+=j.count(a[i])+j.count(a[i].upper())
for i in range(len(a)):
    print(a[i]+" : "+str(counter[i]))

Submission status: Accepted

Solution code:
from collections import Counter
S = ''
while True:
    try:
        s = input().lower()
    except:
        break
    S += s
C = Counter(S)
A = ['a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r',
     's', 't', 'u', 'v', 'w', 'x', 'y', 'z']
for Ai in A:
    print(Ai + ' : ' + '{0}'.format(C[Ai]))

Submission status: Accepted

Solution code:
import sys
S = sys.stdin.read()
for i in range(26):
    ans = S.count(chr(i+65))+S.count(chr(i+97))
    print(f"{chr(i+97)} : {ans}")

Submission status: Accepted

Solution code:
import string
import sys

sent = sys.stdin.read()
sent = sent.lower()
#print(sent)
results = {let: sent.count(let) for let in set(sent)}
alphas = [chr(ord('a') + i) for i in range(26)]

for a in alphas:
    if a not in results:
        print("{} : {}" .format(a, 0))
    else:
        print("{} : {}" .format(a, results[a]))

Submission status: Accepted

Solution code:
# coding: utf-8
# Your code here!

t = ""
y = [0]*26
while True:
    try:
        n = input()
        m = str(n)
        m = m.lower()
        t += m
    except:
        break
for i in range(len(t)):
    x = ord(t[i])
    if x>96 and x<123:
        y[x-97] += 1
for i in range (97,123):
    print(chr(i), ":", y[i-97])

Submission status: Accepted

Solution code:
import sys
lines = sys.stdin.readlines()
x = []

for i,line in enumerate(lines):
    line = line.strip("\n")
    x.append(line)
newx = str.lower("".join(x))
num = ord("a")

for i in range(26):
    countn = newx.count(chr(num))
    print(chr(num) + " : " + str(countn))
    num += 1

Submission status: Accepted

Solution code:
import collections

n = []

while True:
   try:
       N = input()
   
   except:
       break
   
   N = N.lower() 
    
   N.replace('', ' ')
   
   N = list(N)
   
   n.extend(N)
   
c = collections.Counter(n)

for i in range(97, 97+26):
        print("%s : %d" % (chr(i),c[chr(i)]) )

Submission status: Accepted

Solution code:
import sys
x={}
for line in sys.stdin:
    for l in line:
        if l.isalpha():
            c=l.lower()
            x[c]=x.get(c,0)+1
for i in range(26):
    c=chr(ord("a")+i)
    print(f'{c} : {x.get(c,0)}')

Submission status: Accepted

Solution code:
import sys
import string

count={k: 0 for k in string.ascii_lowercase}
for c in sys.stdin.read().lower():
    if c.islower():
        count[c]=count[c]+1
for k,v in count.items():
    print(f"{k} : {v}")

Submission status: Accepted

Solution code:
alpha='abcdefghijklmnopqrstuvwxyz'
text=''

while True:
    try:
        text += input().lower()
    except EOFError:
        break
for a in alpha:
    print('{} : {}'.format(a,text.count(a)))

Submission status: Accepted

Solution code:
import sys
table = [0]*26

a = "abcdefghijklmnopqrstuvwxyz"
b = sys.stdin.read()

for i in b:
    index = 0
    for j in a:
        if i == j or j == i.lower():
            table[index] += 1
            break
        index += 1

for i in range(len(a)):
    print("%s : %d"%(a[i],table[i]))

Submission status: Accepted

Solution code:
l = [0 for i in range(26)] 
b=[chr(ord('a') + i) for i in range(26)]
while True:
    try:
        n=input()
        a= n.lower()
        for i in range(26):
            c = a.count(b[i])
            l[i]+=c
    except EOFError:
        for i in range(26):
            print(f'{b[i]} : {l[i]}')    
        break

Submission status: Accepted

Solution code:
import sys

chars = 'abcdefghijklmnopqrstuvwxyz'
counts = [0]*26

words = sys.stdin.read()
# words = 'This is a pen.'

for A in words:
    index = 0
    for B in chars:
        if A.lower() == B:
            counts[index] += 1
            break
        index += 1

for i in range(len(chars)):
    print(f'{chars[i]} : {counts[i]}')

Submission status: Accepted

Solution code:

# B_C

import sys
import string

text = ''
alpha = string.ascii_lowercase
while True:
    try:
        text += input().lower()
    except EOFError:
        break
for a in alpha:
    print(f"{a} : {text.count(a)}")

Submission status: Accepted

Solution code:
a = [0 for i in range(26)]
while True:
    try:
        s = str(input())
        s = s.lower()
        for i in range(len(s)):
            n = ord(s[i])
            if n > 96 and n < 123:
                a[n-97] += 1
    except:
        break
for i in range(97,123):
    print(chr(i),":",a[i-97])

Submission status: Accepted

Solution code:
k=[0]*26
while True:
    try : n=input()
    except EOFError: break
    for i in range(len(n)):
        a=ord(n[i])-ord('a')            
        if a>=0 and a<26 :
            k[a]+=1
        b=ord(n[i])-ord('A')
        if b>=0 and b<26 :                
            k[b]+=1

for i in range(26):
    print(chr(i+ord('a')),':',k[i])

Submission status: Accepted

Solution code:
import string

C=string.ascii_lowercase

L=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]

try:
    while True:
        A=input()
        
        if(A):
            A=A.lower()
            for i in range(26):
                B=A.count(C[i])
                L[i]+=B
                i+=1
            
        
        
        
except EOFError:
    pass

for j in range(26):
            print(C[j],end='')
            print(' : ',end='')
            print(L[j])
            j+=1

Submission status: Accepted

Solution code:
moji=''
while True:
    try:
        moji+=str(input().lower())
    except EOFError:
        break
for i in range(97,123):
    print(chr(i),':',moji.count(chr(i)))

Submission status: Accepted

Solution code:
import string

def print_frequencies(frequency_dict):
  for letter, count in frequency_dict.items():
    print(f"{letter} : {count}")

def remove_digits(input_str):
  removed_digit_string = ""

  for a in input_str:
    if a.isdigit():
      continue
    else:
      removed_digit_string += a
  
  return removed_digit_string


# Init dictionary of letters and counts
letter_counts = dict.fromkeys(string.ascii_lowercase, 0)

# Replaces all punctuation with empty space
translator = str.maketrans('', '', string.punctuation)

while True:
  try:

    # Keep on concatenating string until end of input
    master_string = ""
    input_text = input()
    master_string += input_text
    
    # Remove punctuation from string
    master_string = master_string.translate(translator)
    master_string = master_string.replace(" ", "")
    
    # Make entire string lowercase
    master_string = master_string.lower()

    # Remove numeric characters
    master_string = remove_digits(master_string)

    # Update frequencies
    for letter in master_string:
      letter_counts[letter] += 1

  # Print frequencies
  except EOFError:
    print_frequencies(letter_counts)
    break

Submission status: Accepted

Solution code:

try:
    a=[]
    while True:
        t=input()
        t=t.lower()
        for j in range(len(t)):
            x=ord(t[j])
            a.append(x)
except EOFError:
    pass

count=[0]*130
for i in a:
    count[i]+=1
    
for i in range(97,123):
    print(chr(i),':',count[i])

Submission status: Accepted

Solution code:
x=[0 for i in range(26)]
a="abcdefghijklmnopqrstuvwxyz"
while True :
    try:
        b=input()
    except:
        break
    for j in b:
        y=0
        for k in a:
            if j == k or j == k.upper():
                x[y]+=1
                break
            y+=1
for i in range(len(a)):
    print("%s : %d"%(a[i],x[i]))

Submission status: Accepted

Solution code:
from collections import Counter
from string import ascii_lowercase

s=""
while 1:
    try:s+=input().lower()
    except EOFError : break

dic=Counter(s)

for x in ascii_lowercase:
    if x in dic:
        print("{} : {}".format(x,dic[x]))
    else :
        print("{} : 0".format(x))

Submission status: Accepted

Solution code:
import sys

s = ""
for line in sys.stdin:
    s += line

char = "abcdefghijklmnopqrstuvwxyz"

for c in char:
    n1 = s.count(c)
    n2 = s.count(c.upper())
    print(c + " : " + str(n1 + n2))

Submission status: Accepted

Solution code:
# coding: utf-8
# Your code here
l="abcdefghijklmnopqrstuvwxyz"
a=[0]*26

while True:    
    try:
        n=input()
        n=n.lower()
        for i in range(len(n)):
            if n[i] in l:
                b=l.index(n[i])
                a[b] +=1
    except:
        break
for c in range(26):
    print(l[c],':',a[c])

Submission status: Accepted

Solution code:
lst = []
while True:
 try:
  lst += input().lower()
 except: break
orda = ord('a')
ordz = ord('z')
for i in range(orda,ordz+1):
 print('{} : {}'.format(chr(i),lst.count(chr(i))))

Submission status: Accepted

Solution code:
a=[0 for code in range(26)]
b= 'abcdefghijklmnopqrstuvwxyz'
while True:
    try:
        c=input()
        for i in range(len(c)):
            if c[i] in b or c[i].lower() in b:
                a[b.index(c[i].lower())]+=1
    except:
        break
for j in range(26) :
    print(f'{b[j]} : {a[j]}')

Submission status: Accepted

Solution code:
s1=''
while True:
    try:
        s1 += input().lower()
    except:
        break
for i in ('a','b','c','d','e','f','g','h','i','j','k','l','m','n','o','p','q','r','s','t','u','v','w','x','y','z'):
    print(i,":",s1.count(i))

Submission status: Accepted

Solution code:
sm = ""
while True:
    try:
        sm += input().lower()
    except:
        break
 
for i in 'abcdefghijklmnopqrstuvwxyz':
    print('{} : {}'.format(i, sm.count(i)))

Submission status: Accepted

Solution code:
#全然賢いやり方あるはず
(a,b,c,d,e,f,g,h,i_i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z)\
    = (0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0)
while True:
    try:
        string = list(input())
    except:
        break
    for i in string:
            if i=="a" or i=="A":
                a += 1
            elif i=="b" or i=="B":
                b += 1
            elif i=="c" or i=="C":
                c += 1
            elif i=="d" or i=="D":
                d += 1
            elif i=="e" or i=="E":
                e += 1
            elif i=="f" or i=="F":
                f += 1
            elif i=="g" or i=="G":
                g += 1
            elif i=="h" or i=="H":
                h += 1
            elif i=="i" or i=="I":
                i_i += 1
            elif i=="j" or i=="J":
                j += 1
            elif i=="k" or i=="K":
                k += 1
            elif i=="l" or i=="L":
                l += 1
            elif i=="m" or i=="M":
                m += 1
            elif i=="n" or i=="N":
                n += 1
            elif i=="o" or i=="O":
                o += 1
            elif i=="p" or i=="P":
                p += 1
            elif i=="q" or i=="Q":
                q += 1
            elif i=="r" or i=="R":
                r += 1
            elif i=="s" or i=="S":
                s += 1
            elif i=="t" or i=="T":
                t += 1
            elif i=="u" or i=="U":
                u += 1
            elif i=="v" or i=="V":
                v += 1
            elif i=="w" or i=="W":
                w += 1
            elif i=="x" or i=="X":
                x += 1
            elif i=="y" or i=="Y":
                y += 1
            elif i=="z" or i=="Z":
                z += 1

print("a : "+str(a))
print("b : "+str(b))
print("c : "+str(c))
print("d : "+str(d))
print("e : "+str(e))
print("f : "+str(f))
print("g : "+str(g))
print("h : "+str(h))
print("i : "+str(i_i))
print("j : "+str(j))
print("k : "+str(k))
print("l : "+str(l))
print("m : "+str(m))
print("n : "+str(n))
print("o : "+str(o))
print("p : "+str(p))
print("q : "+str(q))
print("r : "+str(r))
print("s : "+str(s))
print("t : "+str(t))
print("u : "+str(u))
print("v : "+str(v))
print("w : "+str(w))
print("x : "+str(x))
print("y : "+str(y))
print("z : "+str(z))

Submission status: Accepted

Solution code:
s=''
while True:
    try:
        s += input().lower()
    except EOFError:
        break
S = list(s)
for c in 'abcdefghijklmnopqrstuvwxyz':
    a=S.count(c)
    print(f'{c} : {a}')

Submission status: Accepted

Solution code:
XS = list(open(0).read())
m = {}
for i in range(26):
    m[chr(97+i)] = 0
for x in XS:
    c = x.lower()
    if c in m:
        m[c] += 1
for k, v in m.items():
    print("{} : {}".format(k, v))