Filter löschen
Filter löschen

tilde use before if condition

55 Ansichten (letzte 30 Tage)
boureghda mohammed
boureghda mohammed am 12 Nov. 2016
Kommentiert: Star Strider am 14 Nov. 2016
I was looking at on Matlab code , I could not understand the use of tilde ~ before if condition .
if ~isfield(ArgDS,'mu')

Akzeptierte Antwort

Star Strider
Star Strider am 12 Nov. 2016
The tilde ‘~’ is a logical negation. So the if condition will be true when 'mu' is not a field of the ‘ArgDS’ structure.
  2 Kommentare
boureghda mohammed
boureghda mohammed am 14 Nov. 2016
Thanks for the clarification "Star Strider"
Star Strider
Star Strider am 14 Nov. 2016
My pleasure.

Melden Sie sich an, um zu kommentieren.

Weitere Antworten (0)

Community Treasure Hunt

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

Start Hunting!

Translated by