Monte Carlo Simulation Language Reference Manual Diego Garcia (dg2275) Eita Shuto (es2908) Yunling Wang (yw2291) Chong Zhai (cz2191)MCSL LRM Page 2 of 23 1. Introduction ....................................................................................................................................... 5 Overview ........................................................................................................................................... 5 Goal ................................................................................................................................................... 5 Sub-algorithms: ................................................................................................................................. 5 Key feature ........................................................................................................................................ 6 Hybrid Style ...................................................................................................................................... 6 2. Lexical Conventions ......................................................................................................................... 7 Comments ......................................................................................................................................... 7 Identifiers .......................................................................................................................................... 7 Keywords .......................................................................................................................................... 7 Constants ........................................................................................................................................... 8 Integer constants ............................................................................................................................... 8 Floating constants ............................................................................................................................. 8 Character constants ........................................................................................................................... 8 Strings ............................................................................................................................................... 8 3. Conversions ....................................................................................................................................... 9 Floats and integers ............................................................................................................................ 9 Random type resolution .................................................................................................................... 9 4. Expressions ..................................................................................................................................... 10 Objects and lvalues ......................................................................................................................... 10 Primary expressions ........................................................................................................................ 10 Identifiers .................................................................................................................................... 10 Constants ..................................................................................................................................... 10 Strings ......................................................................................................................................... 10 Parentheses .................................................................................................................................. 10 Functions ..................................................................................................................................... 10 Arrays .......................................................................................................................................... 10 Unary Logical Operator ................................................................................................................... 11 ! operator ...................................................................................................................................... 11 Arithmetic Operators........................................................................................................................ 11 * operator ..................................................................................................................................... 11 _ operator ..................................................................................................................................... 11 operator ........................................................................................................................................ 11 % operator .................................................................................................................................... 11MCSL LRM Page 3 of 23 + operator ..................................................................................................................................... 11 - operator ...................................................................................................................................... 11 Comparison operators ..................................................................................................................... 12 < operator .................................................................................................................................... 12 > operator .................................................................................................................................... 12 <= operator .................................................................................................................................. 12 >= operator .................................................................................................................................. 12 == operator .................................................................................................................................. 12 != operator
View Full Document