Not sure I understand what you mean. You can have a variable that is an integer type (say uint8 which is basically a byte with 0-255). The function checks if it is an integer variable.
-
-
2 replies 0 retweets 0 likes
-
-
Basically, I am talking about best practices in dynamically types languages. It's a programming issue you learn in undergrad in computer science — sorry I was unclear!
1 reply 0 retweets 0 likes -
You need a try-catch block since it's dynamically typed.
1 reply 0 retweets 0 likes -
I try (ironic) to avoid try-catch clauses like the plague. Anyway, only got up cause I couldn't sleep but I'm going back to bed now... :)
1 reply 0 retweets 0 likes -
Exception handling is really good practice.
1 reply 0 retweets 3 likes -
Yes perhaps I'm missing another thing here. I meant actual try-catch in Matlab where you don't know what the error is in the end. Makes things very hard to debug.
1 reply 0 retweets 0 likes -
You know the error, that is how you catch it. See section called "Handle Different Types of Errors": http://se.mathworks.com/help/matlab/ref/try.html …
2 replies 0 retweets 1 like -
Surely you wouldn't want to do this for every line of code? Anyway, thanks for the discussion. I do with I could go back to when I still used C/C++ but that's not realistic...
1 reply 0 retweets 0 likes
No, not for every line of code.
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.