How do I get the only the integer part?

69 次查看(过去 30 天)
I want to get the 1846,but I get the 1845.Why is that?
Is there any other good way?
a=1.8460e+03;
a1=fix(a);
>>
1845

采纳的回答

KSSV
KSSV 2022-10-11
a=1.8460e+03;
round(a)
ans = 1846

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 MATLAB 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by