note 58982 deleted from function.ceil by googleguy
| From: | googleguy@php.net | Date: | Tue, 22 Oct 2013 14:54:45 +0000 |
| Subject: | note 58982 deleted from function.ceil by googleguy | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-197227@lists.php.net to get a copy of this message | ||
Note Submitter: nobody
----
Here's a more simple one to do ceil to nearest 10:
function ceilpow10(val) {
if (val % 10 == 0) return val;
return val + (10 - (val % 10));
}