We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
defprimeCount(n):# Write your code herex=0s=1foriinrange(2,n+1):flag=Trueforjinrange(2,int(math.sqrt(i))+1):ifi%j==0:flag=Falsebreakifflag:s*=iifs>n:breakx+=1returnx
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
Leonardo's Prime Factors
You are viewing a single comment's thread. Return to all comments →