Remote-processing CAMBASIC Manual do Utilizador Página 144

  • Descarregar
  • Adicionar aos meus manuais
  • Imprimir
  • Página
    / 208
  • Índice
  • MARCADORES
  • Avaliado. / 5. Com base em avaliações de clientes
Vista de página 143
Commands - 111
RND
Numeric Fun ction
SYNTAX: n = RND(m)
PURPOSE: To return a pseudo– random number between 0 and 1.
REMARK S: The RND function returns a pseudo– random num ber between 0 and 1.
An m of less than zero will initialize the pseudo– random num ber sequence. Each time the
pseudo random number generator is initialized with the same m number, it will produce the same
sequence of pseudo– random number s.
An m of zero will cause RND to return the previous random number.
An m of greater than zero will cause RND to return the next random number in the sequence.
EXAMPLE: 10 R = RND(–1)
20 S = RND(0)
30 T = RND(1)
40 PRINT R,S,T
RUN
7.65943E–06 7.65943E–06 .163989
ERROR: none
Vista de página 143
1 2 ... 139 140 141 142 143 144 145 146 147 148 149 ... 207 208

Comentários a estes Manuais

Sem comentários