This is part of the HicEst documentation
DATA: Initialize Numeric Entities at Compile Time
A DATA statement assigns initial values to numeric variables before program execution. Related are the REAL and CHARACTER statements.
⇾Home
⇾Contents
⇾more Programming
⇾ Examples
DATA variable/NumericConstant/ [, variable/NumericConstant/, ...]
DATA array[(i [,j])]/NumericConstant [,NumericConstant,..]/
2-dimensional arrays are stored
row by row
in
HicEst
examples:
DATA L/5/
! defines the variable L and defines its value at compile time
DIMENSION
vector(L)
! defines a vector of length L
DATA vector/5, 4, 3, 2, 1/
! set the elements of vector at compile time
REAL
:: m=3, n=4, matrix(m, n)
! another way to define scalars and arrays
DATA matrix/1, 2, 3, 4, 5, 6, 7, 8, 9/
! set matrix row by row
DATA matrix(2,1)/-21,-22,-23/
! set the first 3 elements of row2
⇾
Support HicEst
⇾
Impressum
©2000-2019 Georg Petrich, HicEst Instant Prototype Computing. All rights reserved.