Round Numbers to Nearest Multiple of 5

  • Thread starter Thread starter powp
  • Start date Start date
AI Thread Summary
To round a number to the nearest multiple of 5, one can use a simple formula: round up any number that is not already a multiple of 5. For example, 22 rounds up to 25, while 20 remains 20. Additionally, there is a request for information on calculating the floor function, which is relevant for rounding down to the nearest integer. The discussion emphasizes the importance of showing attempts in a homework context. Clear methods for rounding and understanding floor functions are sought for educational purposes.
powp
Messages
91
Reaction score
0
Hello

I need to create a one line statement to round number up to nearest multiple of 5

so if I have a number 22 the result should be 25
so if I have a number 20 the result should be 20

or does anybody know how to calculate floor function?

Thanks
 
Mathematics news on Phys.org
This should be in the homework section, and you should show your attempts first.
 
Thread 'Video on imaginary numbers and some queries'
Hi, I was watching the following video. I found some points confusing. Could you please help me to understand the gaps? Thanks, in advance! Question 1: Around 4:22, the video says the following. So for those mathematicians, negative numbers didn't exist. You could subtract, that is find the difference between two positive quantities, but you couldn't have a negative answer or negative coefficients. Mathematicians were so averse to negative numbers that there was no single quadratic...
Insights auto threads is broken atm, so I'm manually creating these for new Insight articles. In Dirac’s Principles of Quantum Mechanics published in 1930 he introduced a “convenient notation” he referred to as a “delta function” which he treated as a continuum analog to the discrete Kronecker delta. The Kronecker delta is simply the indexed components of the identity operator in matrix algebra Source: https://www.physicsforums.com/insights/what-exactly-is-diracs-delta-function/ by...
Suppose ,instead of the usual x,y coordinate system with an I basis vector along the x -axis and a corresponding j basis vector along the y-axis we instead have a different pair of basis vectors ,call them e and f along their respective axes. I have seen that this is an important subject in maths My question is what physical applications does such a model apply to? I am asking here because I have devoted quite a lot of time in the past to understanding convectors and the dual...
Back
Top