How to compare the strings inside the gui

1 Ansicht (letzte 30 Tage)
han han
han han am 23 Sep. 2019
Beantwortet: Walter Roberson am 23 Sep. 2019
How to compare the strings inside the gui llike this
Ex. If the student number is A01, the male student is displayed, otherwise the female student is displayed.
I have read the syntax of strcmp, but I don't know how to use it.
please help me

Akzeptierte Antwort

Walter Roberson
Walter Roberson am 23 Sep. 2019
if strcmp(Student_Number, 'A01')
disp('the male student')
else
disp('the female student')
end

Weitere Antworten (0)

Kategorien

Mehr zu Migrate GUIDE Apps finden Sie in Help Center und File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by