Skip to content

Commit

Permalink
updated example!!
Browse files Browse the repository at this point in the history
  • Loading branch information
Jonak-Adipta-Kalita committed May 4, 2023
1 parent 94d2161 commit 0f1d179
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions examples/helloWorld.jak
Original file line number Diff line number Diff line change
Expand Up @@ -12,17 +12,23 @@ var helloWorldHash = {
var helloWorldArray = [helloWorldHash];

if (true) {
var helloWorldHash_two = {
mut helloWorldArray = append(helloWorldArray, {
"hello": "Konnichiwa",
"world": "Sekai"
};
var helloWorldArray = push(helloWorldArray, helloWorldHash_two);
});
}

var counter = 1;
var index = 0;

for (counter > 5) {
print(HelloWorld(helloWorldArray[1]["hello"], helloWorldArray[1]["world"]));
if ((counter % 2) == 0) {
mut index = 1;
} else {
mut index = 0;
}

print(HelloWorld(helloWorldArray[index]["hello"], helloWorldArray[index]["world"]));
counter++;
}

0 comments on commit 0f1d179

Please sign in to comment.