Creating a fucning in spesific format

I want to create a fucntion that display the input variable in long format.
How can I do it ?

 Accepted Answer

You may consider using fprintf() by specifying the format specs, e.g.:
F = pi;
fprintf('F = %3.15f \n', F)
F = 3.141592653589793

More Answers (0)

Categories

Community Treasure Hunt

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

Start Hunting!