Please ensure Javascript is enabled for purposes of website accessibility
Powered by Zoomin Software. For more details please contactZoomin

Hull and Outfitting

Assignment

  • Last UpdatedFeb 08, 2023
  • 1 minute read

Assignment always makes a copy of the right-hand-side to replace what is on the left-hand-side. The following command copies !Y into !X:

!X = !Y

If, for example, !Y is an array, this command will duplicate the entire array making a copy of each of the array elements. The same is true if !Y is an OBJECT.

The technical term for this is deep copy. Following this copy

!X[1] = ‘New Value’

will change !X[1] but leave the original array !Y unchanged.

TitleResults for “How to create a CRG?”Also Available in