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.
I am just iterating through the multiples nmax within the range of nmax to nmin because the non multiples nmax are however not gonna satisfy the conditions provided so we can just skip these numbers increasing speed of the overall execution.
range(1,int(nmin/nmax)+1)
The range gives the count of multiples of nmax present within the range of nmax and nmin
e.g
nmax=4
nmin=12
So, range(1,int(nmin/nmax)+1) = range(1,4) = [1,2,3]
There are 3 multiples of 3 within the range of 3 to 6
Between Two Sets
You are viewing a single comment's thread. Return to all comments →
I am just iterating through the multiples nmax within the range of nmax to nmin because the non multiples nmax are however not gonna satisfy the conditions provided so we can just skip these numbers increasing speed of the overall execution.
The range gives the count of multiples of nmax present within the range of nmax and nmin
e.g
nmax=4
nmin=12
So, range(1,int(nmin/nmax)+1) = range(1,4) = [1,2,3]
There are 3 multiples of 3 within the range of 3 to 6
Hope this helps.