Can anyone explain how to count the number of capital letters in a file?
You can use this piece of code, I hope this will help you:
with open('Today.txt') as today:
for i in today.read():
n = int (input ('ENTER NUMBER TO ...READ MORE
a = int (input('enter number'))
num = a
sum ...READ MORE
Assumming a is a string. The Slice ...READ MORE
Hi. Nice question.
Here is the simplified answer ...READ MORE
You can also use the random library's ...READ MORE
colors = ['red', 'green', ...READ MORE
Enumerate() method adds a counter to an ...READ MORE
You can simply the built-in function in ...READ MORE
To count the number of appearances:
from collections ...READ MORE
A module is a file containing a ...READ MORE
At least 1 upper-case and 1 lower-case letter
Minimum 8 characters and Maximum 50 characters
Already have an account? Sign in.