my_file=open('z5.txt', 'w')
my_file.write('Birds are animal with feathers. Because they can fly, they are the fastest animals on Earth')
my_file.close()
my_file=open('z5.txt')
my_string=my_file.read()
print('прочитано:')
print(my_string)
import requests
url = 'https://oeis.org/A000040/a000040.txt'
txt = 'Birds are animal with feathers. Because they can fly, they are the fastest animals on Earth'
def is_prime(number, primes={*requests.get(url).text.split()[1::2]}):
return str(number) in primes
for index, char in enumerate(txt, 1):
if is_prime(index):
print(char, end=' ')