© The Author(s), under exclusive license to APress Media, LLC, part of Springer Nature 2022
A. DanialPython for MATLAB Developmenthttps://doi.org/10.1007/978-1-4842-7223-7_15

15. Language Pitfalls

Albert Danial1  
(1)
Redondo Beach, CA, USA
 

15.1 Troublesome Language Features

Neither MATLAB nor Python are ideal languages. Both have annoying and downright dangerous aspects—at least for novice programmers unfamiliar with more subtle aspects of the languages’ designs. Detractors of one or the other language are keen to point out the other’s flaws while brushing off criticism of their preferred language.

15.2 MATLAB

  • Dangerous: Mixed-type mathematical expressions are typecast downward instead of upward.

>> a = uint8(1) - 0.6
a =
    uint8
    0
The result of ...

Get Python for MATLAB Development: Extend MATLAB with 300,000+ Modules from the Python Package Index now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.