if expression

This commit is contained in:
Ginger Bill
2016-12-30 16:21:45 +00:00
parent 23d32f34e5
commit 2ecafda1d3
6 changed files with 222 additions and 43 deletions
+6 -3
View File
@@ -12,8 +12,11 @@ import {
}
proc main() {
var a, b, c = {
give 1, 2, 123*321;
var cond = true;
var msg = if cond {
give "hello";
} else {
give "goodbye";
};
fmt.println(a, b, c);
fmt.println(msg);
}