Azzera filtri
Azzera filtri

How do I get the only the integer part?

32 visualizzazioni (ultimi 30 giorni)
zl
zl il 11 Ott 2022
Commentato: zl il 11 Ott 2022
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

Risposta accettata

KSSV
KSSV il 11 Ott 2022
a=1.8460e+03;
round(a)
ans = 1846

Più risposte (0)

Categorie

Scopri di più su Graph and Network Algorithms in Help Center e File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by