Hi:
Matlab "round" function can specify which decima to "round at", but there is no similar feature to "ceil" function.
for example, integer 1234,
round(1234,-1) get a result 1230, but is there any quick way to get number 1240?
Thanks!

답변 (1개)

dpb
dpb 2022년 11월 18일

0 개 추천

>> ceil(x/10)*10
ans =
1240.00
>>

카테고리

도움말 센터File Exchange에서 Function Creation에 대해 자세히 알아보기

질문:

2022년 11월 18일

답변:

dpb
2022년 11월 18일

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by