Teledyne-lecroy Protocol Analyzers File-Based Decoding User Manual Manual do Utilizador Página 13

  • Descarregar
  • Adicionar aos meus manuais
  • Imprimir
  • Página
    / 82
  • Índice
  • MARCADORES
  • Avaliado. / 5. Com base em avaliações de clientes
Vista de página 12
File-based Decoding User Manual Chapter 3: Expressions
LeCroy Corporation 7
Chapter 3: Expressions
An expression is a statement that calculates a value. The simplest type of expression is
assignment:
x = 2
The expression x = 2 calculates 2 as the value of x.
All expressions contain operators, which are described in
Chapter 4, Operators, on page 9. The operators indicate how an expression should be
evaluated in order to arrive at its value. For example
x + 2
says to add 2 to x to find the value of the expression. Another example is
x > 2
which indicates that x is greater than 2. This is a Boolean expression, so it evaluates to
either true or false. Therefore, if
x = 3, then x > 2 evaluates to true; if x = 1, it returns
false.
True is denoted by a non-zero integer (any integer except 0), and false is a zero integer
(0). True and false are also supported for lists (an empty list is false, while all others are
true), and strings (an empty string is false, while all others are true), and
null is
considered false. However, all Boolean operators result in integer values.
Vista de página 12
1 2 ... 8 9 10 11 12 13 14 15 16 17 18 ... 81 82

Comentários a estes Manuais

Sem comentários