Q:

Use the cast function to cast a variable to be the same type as another variable

0

 Use the cast function to cast a variable to be the same type as another variable. 

All Answers

need an explanation for this answer? contact us directly to get an explanation for this answer

>> vara = uint16(3 + 5) vara = 8 >> varb = 4*5; >> class(varb) ans = double >> varb = cast(varb, 'like', vara) varb = 20 >> class(varb) ans = uint16

need an explanation for this answer? contact us directly to get an explanation for this answer

total answers (1)

Similar questions


need a help?


find thousands of online teachers now