Hi,I have to reverse a number.Ex.4530 .I have to print this number as 0354 and not as 354.Is there any way to print the number including '0' also.Please help!Thank you.

 采纳的回答

flip(sprintf('%d',4530),2)

3 个评论

Thank you so much Sir. Can you please explain me how this syntax works sir.
Please read help for Matlab

请先登录,再进行评论。

更多回答(0 个)

类别

Community Treasure Hunt

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

Start Hunting!

Translated by