Unformatted text preview: >> bolts = 18; >> rivets = 40; >> items = screws + bolts + rivets items = 90 >> screws = 36 screws = 36 >> items items = 90 After computing items , screws was changed to 36, overwriting its previous value of 32. Note that the value of items has not changed. Unlike a spreadsheet, Matlab does not recalculate the number of items based on the new value of screws . When Matlab performs a calculation, it does so using the values it knows at the time the requested command is evaluated. In this example, to recalculate items , the items assignment statement must be re-issued: 22...
View Full Document
- Summer '09
- English, Imperative programming, array array array