gitweb on Svarog
projekti pod git sistemom za održavanje verzija -- projects under the git version control system
summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 9e84964)
raw | patch | inline | side by side (parent: 9e84964)
author | Doni Pracner <quinnuendo@gmail.com> | |
Wed, 30 Jul 2014 20:18:07 +0000 (22:18 +0200) | ||
committer | Doni Pracner <quinnuendo@gmail.com> | |
Wed, 30 Jul 2014 20:18:07 +0000 (22:18 +0200) |
samples/InOut2.mj | [new file with mode: 0644] | patch | blob |
samples/InOut3.mj | [new file with mode: 0644] | patch | blob |
diff --git a/samples/InOut2.mj b/samples/InOut2.mj
--- /dev/null
+++ b/samples/InOut2.mj
@@ -0,0 +1,10 @@
+program InOut2{
+ void main()
+ char c;
+ {
+ print('c');
+ print('?');
+ read(c);
+ print(c);
+ }
+}
\ No newline at end of file
diff --git a/samples/InOut3.mj b/samples/InOut3.mj
--- /dev/null
+++ b/samples/InOut3.mj
@@ -0,0 +1,23 @@
+program InOut3{
+ void main()
+ char c;
+ int i;
+ {
+ i = 5;
+ print('c');
+ print('?');
+ read(c);
+ print(c);
+ print(chr(10));
+ if (c=='y') {
+ print('i');
+ read(i);
+ } else {
+ print('c');
+ read(c);
+ }
+ print(chr(10));
+ print(i,5);
+ print(c,5);
+ }
+}
\ No newline at end of file