write an algorithm to find the sum of all the prime numbers of the given range character
Answers
Answered by
0
Answer:
56789235s mar ke liye bhej diya gaya
Answered by
1
print("This is an algorithm to print the sum of all the prime numbers of the given range character.")
n=int(input("Enter the maximum value the last prime number should be less than:")
check=""
count=0
prl=[]
for i in range(n):
for j in range((i/2)+1):
check=check+(i%j)
for j in range(len(check)):
if ch[j] is 0:
count=count+1
if count is 0:
prl.append(i)
psq=sum(prl)
print("The sum of all the prime numbers in the given range is", psq)
Similar questions