From 04ee7d77c062f6903466137c31da7e78a6b5d0c1 Mon Sep 17 00:00:00 2001 From: Max Wash Date: Wed, 4 Dec 2024 16:35:54 +0000 Subject: [PATCH] doc: add more complex expressions to sample file --- doc/sample/Expressions.im | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/doc/sample/Expressions.im b/doc/sample/Expressions.im index cfca382..bf82c8a 100644 --- a/doc/sample/Expressions.im +++ b/doc/sample/Expressions.im @@ -1,4 +1,4 @@ - +/* y = 1 + 2 * 3 / 4 * 5 - 6 + 7 multiplyBy:2. z = w = 2 + 3 multiplyBy:2. x = (((1 + 2 * 3) multiplyBy:3) add: 5) + 2. @@ -23,4 +23,11 @@ x = OrderedCollection new age = Person new(name:"John Doe" age:34) setAge:144 inUnit:"months"; - ageInMonths. \ No newline at end of file + ageInMonths. +*/ + +--x = 5. +--q = 10 if x > 2. +--q = if x > 2 then 10 else 20 end. + +cout put:5 multiply(by:5 add:2). \ No newline at end of file