I don't understand if the smallest element should be the last or the first of the sorted array
Thanks for creating a problem! It's a little ambiguous right now (see @andrea84's comment above). There is more than one answer as currently defined. Could you please clarify it?
Sorry for that, if you have input odd vector the smallest element is on the end, but if u input even vector the smallest element is on the first position.
Solve the Sudoku Row
Get the length of a given vector
Largest Twin Primes
Concatenate two strings
Find the treasures in MATLAB Central and discover how the community can help you!
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Contact your local office