how do i print the 3 most common word that begins with capitals? also how do i count how many times they appear?

Show us some work, and we will help you

Just some tips,you have to do something yourself.

This regex [A-Z]\w will match Hi and My.
---
Hi this is a test.
My car is red.
---

import string
>>> string.ascii_uppercase
'ABCDEFGHIJKLMNOPQRSTUVWXYZ'

#-------#
>>> for num in range(65, 91):
...     capLetter = chr(num)
...     print capLetter
...     
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
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.