Initial data commit
This commit is contained in:
parent
72d218235f
commit
f23f22d71c
199087 changed files with 3378941 additions and 0 deletions
15
Task/Stack/Jsish/stack.jsish
Normal file
15
Task/Stack/Jsish/stack.jsish
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
/* Stack, is Jsish */
|
||||
var stack = [];
|
||||
puts('depth:', stack.length);
|
||||
|
||||
stack.push(42);
|
||||
stack.push('abc');
|
||||
puts('depth:', stack.length);
|
||||
|
||||
puts('popped:', stack.pop());
|
||||
if (stack.length) printf('not '); printf('empty\n');
|
||||
puts('top:', stack[stack.length-1]);
|
||||
puts('popped:', stack.pop());
|
||||
if (stack.length) printf('not '); printf('empty\n');
|
||||
|
||||
puts('depth:', stack.length);
|
||||
Loading…
Add table
Add a link
Reference in a new issue