MATLAB question on the blank lines describe what matlab is d

MATLAB question. on the blank lines describe what matlab is doing.

abcd abcd abcde r using Matrix dimensions must agree. strcmp abcd abcde strcmp (\'abcd\', \'abcd\') \'abc\' \'a\' strcmpi \'ABcd\', \'abcd\')

Solution

\'abcd\'==\'abcd\' % it prints the true if characters matching at same index positions

\'abcd\'==\'abcde\' % size dimention is not equal (i.e 4 and 5 unequal)

strcmp(\'abcd\',\'abcde\') % string comparasion here returns zero, because its false ( because string not equal)

strcmp(\'abcd\',\'abcd\') % string comparasion retuns (true )one, because strings are equal

strcmpi(\'ABCD\',\'abcd\') % strcmpi performs the comparison without sensitivity to letter case.

 MATLAB question. on the blank lines describe what matlab is doing. abcd abcd abcde r using Matrix dimensions must agree. strcmp abcd abcde strcmp (\'abcd\', \'

Get Help Now

Submit a Take Down Notice

Tutor
Tutor: Dr Jack
Most rated tutor on our site