y = fix(x);
The solution which I presented just now works perfectly fine on the live editor of Matlab, but don't know why math works still say it is incorrect?
use fix instead of floor or ceil command
651 Solvers
Project Euler: Problem 10, Sum of Primes
709 Solvers
701 Solvers
Calculate the area of a triangle between three points
879 Solvers
191 Solvers
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!