Rounding statment (1 Viewer)

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

91
0
Hello

I need to create a one line statment 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
 

DaveC426913

Gold Member
17,752
1,501
This should be in the homework section, and you should show your attempts first.
 

The Physics Forums Way

We Value Quality
• Topics based on mainstream science
• Proper English grammar and spelling
We Value Civility
• Positive and compassionate attitudes
• Patience while debating
We Value Productivity
• Disciplined to remain on-topic
• Recognition of own weaknesses
• Solo and co-op problem solving
Top