11.04.2013 Views

UniBasic Commands Reference - Rocket Software

UniBasic Commands Reference - Rocket Software

UniBasic Commands Reference - Rocket Software

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Parameters<br />

The following table describes each parameter of the syntax.<br />

Parameter Description<br />

dim.array Specifies a dimensioned array to receive new values.<br />

expr Specifies the value to assign to the array elements. expr can be any<br />

<strong>UniBasic</strong> expression.<br />

expr can be an empty string, a formula, a single value, a literal string, or a<br />

function.<br />

dim.array2 Specifies a dimensioned array from which to assign values.<br />

MAT Parameters<br />

Examples<br />

In the following example, the program segment assigns 1.5 to all elements of the<br />

array FEES:<br />

DIM FEES(100,100)<br />

MAT FEES = 1.5<br />

In the next example, the program segment assigns the values in dimensioned array<br />

FEE2 to the dimensioned array FEE1. Note the differing dimensions but the same<br />

number of elements in the two matrices.<br />

DIM FEE1(2,4),FEE2(4,2)<br />

MAT FEE1 = MAT FEE2<br />

If the arrays contain the following values before the assignment:<br />

dimensioned array FEE1 dimensioned array FEE2<br />

1 2 3 4<br />

5 6 7 8<br />

10 11<br />

12 13<br />

14 15<br />

16 17<br />

MAT 1-437

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!