Need list of all not recommended keywords

6 Ansichten (letzte 30 Tage)
Praveen Kumar
Praveen Kumar am 17 Okt. 2019
Kommentiert: Walter Roberson am 11 Nov. 2020
Where can i get all not recommended keywords in R2019b. Could you guys Please tell me as soon as possible.
  3 Kommentare
Guillaume
Guillaume am 17 Okt. 2019
Bearbeitet: Walter Roberson am 5 Dez. 2019
Some context for the question would be welcome. For a start it's not even clear what is meant by keword. For what matlab considers to be a keyword, see Ekemini's answer.
Walter Roberson
Walter Roberson am 5 Dez. 2019
Using the names of any of the functions in basic MATLAB is also not recommended. For example avoid using sum as the name of a variable.
A few days ago we saw someone use ones as the name of a variable, and then got confused over why their calls to the function ones were not working.

Melden Sie sich an, um zu kommentieren.

Antworten (3)

Ekemini Stephen
Ekemini Stephen am 17 Okt. 2019
To obtain a list of all MATLAB keywords, use 'iskeyword' command and the results are shown below. 'break' 'case' 'catch' 'classdef' 'continue' 'else' 'elseif' 'end' 'for' 'function' 'global' 'if' 'otherwise' 'parfor' 'persistent' 'return' 'spmd' 'switch' 'try' 'while'

Karthikeyan S
Karthikeyan S am 5 Dez. 2019

shanjmuka sri ranganadham
shanjmuka sri ranganadham am 11 Nov. 2020
hlo
can you say the keywords used in matlab
  1 Kommentar
Walter Roberson
Walter Roberson am 11 Nov. 2020
As Ekemini Stephen mentioned, use iskeyword()
{'break' }
{'case' }
{'catch' }
{'classdef' }
{'continue' }
{'else' }
{'elseif' }
{'end' }
{'for' }
{'function' }
{'global' }
{'if' }
{'otherwise' }
{'parfor' }
{'persistent'}
{'return' }
{'spmd' }
{'switch' }
{'try'

Melden Sie sich an, um zu kommentieren.

Kategorien

Mehr zu Loops and Conditional Statements finden Sie in Help Center und File Exchange

Produkte

Community Treasure Hunt

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

Start Hunting!

Translated by