X-Git-Url: http://git.harvie.cz/?a=blobdiff_plain;f=demos%2Fadvanced-hello-world.c;h=124788a5f180d5cb9a86f637898fe31d91a900a3;hb=3f49056d3d4121eff6a0777c7b24c13c54fc0953;hp=07a14b851a91763e7b8a46283dce1f3b48c2e8b7;hpb=f57259369784a5df46b75488d50e431ed1741235;p=svn%2FCll1h%2F.git diff --git a/demos/advanced-hello-world.c b/demos/advanced-hello-world.c index 07a14b8..124788a 100644 --- a/demos/advanced-hello-world.c +++ b/demos/advanced-hello-world.c @@ -7,15 +7,27 @@ program print("* print()"); print("Hello","world","!"); print("* NIL"); - print("We can print",NULL,"safely."); - NIL="(anything)"; - print("We can print",NULL,"safely."); - print("* coalesce():"); - print("We can",coalesce("print","everything"),coalesce(NULL,"everything"),"safely."); + print("We can print", NULL, "safely."); + NIL="(hic sunt crocodiles)"; + print("We can print", NULL, "safely."); + + { + str p = "print", a = NULL; + print("* coalesce():"); + print("We can", coalesce(p, "everything"), "almost", coalesce(a, "anything"), "safely."); + } + + echo("Surprisingly ->",NIL," (you can't see this)"); + print("<- nothing special here."); print("* OFS"); + OFS=""; + EOL=""; + print("We","Can","Print","Without","Spaces","BetweenArgs."); OFS=":"; - print("We","can","customize","print"); + print("We","can","customize","print."); OFS="..."; + EOL="<--\n"; + print(""); print("* MAYBE ?"); repeat(4) print((MAYBE ? "Hello" : "Hi"), (MAYBE ? "world" : "friend"), (MAYBE ? "!" : "?")); print("* WHOKNOWS ?");