id
int64
1
2.26k
language
stringclasses
7 values
category
stringclasses
3 values
difficulty
stringclasses
2 values
task_description
stringclasses
132 values
code
stringlengths
68
753
explanation
stringclasses
449 values
801
JavaScript
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, pop, push, push.
class ContainerStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } const s = new ContainerStack(); s.push(13); console.log(s.pop()); s.push(50); s.push(3);
Stack with int elements, ops=['push', 'pop', 'push', 'push'].
802
JavaScript
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, pop, push, push.
class QStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } const s = new QStack(); s.push(2); console.log(s.pop()); s.push(83); s.push(6);
Stack with int elements, ops=['push', 'pop', 'push', 'push'].
803
JavaScript
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, pop, push, push.
class SStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } const s = new SStack(); s.push(32); console.log(s.pop()); s.push(11); s.push(35);
Stack with int elements, ops=['push', 'pop', 'push', 'push'].
804
JavaScript
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, pop, push, push.
class SStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } const s = new SStack(); s.push(81); console.log(s.pop()); s.push(2); s.push(2);
Stack with int elements, ops=['push', 'pop', 'push', 'push'].
805
JavaScript
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, push, pop.
class QStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } const s = new QStack(); s.push(54.69); s.push(82.01); s.push(85.42); console.log(s.pop());
Stack with float elements, ops=['push', 'push', 'push', 'pop'].
806
JavaScript
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, push, pop.
class SStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } const s = new SStack(); s.push(48.56); s.push(56.72); s.push(44.99); console.log(s.pop());
Stack with float elements, ops=['push', 'push', 'push', 'pop'].
807
JavaScript
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, push, pop.
class BufStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } const s = new BufStack(); s.push(48.41); s.push(25.14); s.push(54.81); console.log(s.pop());
Stack with float elements, ops=['push', 'push', 'push', 'pop'].
808
JavaScript
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, push, pop.
class ContainerStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } const s = new ContainerStack(); s.push(13.18); s.push(82.67); s.push(11.18); console.log(s.pop());
Stack with float elements, ops=['push', 'push', 'push', 'pop'].
809
JavaScript
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, pop, push, pop.
class ContainerStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } const s = new ContainerStack(); s.push(88.76); s.push(42.11); console.log(s.pop()); s.push(23.21); console.log(s.pop());
Stack with float elements, ops=['push', 'push', 'pop', 'push', 'pop'].
810
JavaScript
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, pop, push, pop.
class Box_Stack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } const s = new Box_Stack(); s.push(15.59); s.push(65.88); console.log(s.pop()); s.push(88.02); console.log(s.pop());
Stack with float elements, ops=['push', 'push', 'pop', 'push', 'pop'].
811
JavaScript
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, pop, push, pop.
class CollStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } const s = new CollStack(); s.push(82.46); s.push(12.13); console.log(s.pop()); s.push(11.9); console.log(s.pop());
Stack with float elements, ops=['push', 'push', 'pop', 'push', 'pop'].
812
JavaScript
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, pop, push, pop.
class BufStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } const s = new BufStack(); s.push(36.37); s.push(61.95); console.log(s.pop()); s.push(92.41); console.log(s.pop());
Stack with float elements, ops=['push', 'push', 'pop', 'push', 'pop'].
813
JavaScript
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, push, push, pop, pop.
class QStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } const s = new QStack(); s.push(60.85); s.push(18.63); s.push(53.52); s.push(60.36); console.log(s.pop()); console.log(s.pop());
Stack with float elements, ops=['push', 'push', 'push', 'push', 'pop', 'pop'].
814
JavaScript
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, push, push, pop, pop.
class CollStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } const s = new CollStack(); s.push(69.03); s.push(62.85); s.push(29.41); s.push(87.66); console.log(s.pop()); console.log(s.pop());
Stack with float elements, ops=['push', 'push', 'push', 'push', 'pop', 'pop'].
815
JavaScript
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, push, push, pop, pop.
class BufStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } const s = new BufStack(); s.push(93.36); s.push(81.26); s.push(71.42); s.push(8.56); console.log(s.pop()); console.log(s.pop());
Stack with float elements, ops=['push', 'push', 'push', 'push', 'pop', 'pop'].
816
JavaScript
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, push, push, pop, pop.
class SStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } const s = new SStack(); s.push(78.0); s.push(15.51); s.push(15.63); s.push(45.22); console.log(s.pop()); console.log(s.pop());
Stack with float elements, ops=['push', 'push', 'push', 'push', 'pop', 'pop'].
817
JavaScript
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, pop, push, push.
class QStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } const s = new QStack(); s.push(12.2); console.log(s.pop()); s.push(72.94); s.push(15.32);
Stack with float elements, ops=['push', 'pop', 'push', 'push'].
818
JavaScript
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, pop, push, push.
class BufStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } const s = new BufStack(); s.push(99.48); console.log(s.pop()); s.push(39.12); s.push(32.61);
Stack with float elements, ops=['push', 'pop', 'push', 'push'].
819
JavaScript
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, pop, push, push.
class Box_Stack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } const s = new Box_Stack(); s.push(48.65); console.log(s.pop()); s.push(60.57); s.push(64.02);
Stack with float elements, ops=['push', 'pop', 'push', 'push'].
820
JavaScript
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, pop, push, push.
class SStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } const s = new SStack(); s.push(80.41); console.log(s.pop()); s.push(25.34); s.push(42.45);
Stack with float elements, ops=['push', 'pop', 'push', 'push'].
821
Node.js
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, push, pop.
class Box_Stack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { Box_Stack }; const s = new Box_Stack(); s.push(69); s.push(69); s.push(64); console.log(s.pop());
Stack with int elements, ops=['push', 'push', 'push', 'pop'].
822
Node.js
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, push, pop.
class ContainerStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { ContainerStack }; const s = new ContainerStack(); s.push(30); s.push(50); s.push(11); console.log(s.pop());
Stack with int elements, ops=['push', 'push', 'push', 'pop'].
823
Node.js
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, push, pop.
class CollStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { CollStack }; const s = new CollStack(); s.push(54); s.push(68); s.push(74); console.log(s.pop());
Stack with int elements, ops=['push', 'push', 'push', 'pop'].
824
Node.js
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, push, pop.
class CollStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { CollStack }; const s = new CollStack(); s.push(96); s.push(29); s.push(90); console.log(s.pop());
Stack with int elements, ops=['push', 'push', 'push', 'pop'].
825
Node.js
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, pop, push, pop.
class SStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { SStack }; const s = new SStack(); s.push(47); s.push(1); console.log(s.pop()); s.push(3); console.log(s.pop());
Stack with int elements, ops=['push', 'push', 'pop', 'push', 'pop'].
826
Node.js
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, pop, push, pop.
class ContainerStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { ContainerStack }; const s = new ContainerStack(); s.push(61); s.push(18); console.log(s.pop()); s.push(8); console.log(s.pop...
Stack with int elements, ops=['push', 'push', 'pop', 'push', 'pop'].
827
Node.js
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, pop, push, pop.
class BufStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { BufStack }; const s = new BufStack(); s.push(100); s.push(18); console.log(s.pop()); s.push(59); console.log(s.pop());
Stack with int elements, ops=['push', 'push', 'pop', 'push', 'pop'].
828
Node.js
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, pop, push, pop.
class ContainerStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { ContainerStack }; const s = new ContainerStack(); s.push(54); s.push(32); console.log(s.pop()); s.push(29); console.log(s.po...
Stack with int elements, ops=['push', 'push', 'pop', 'push', 'pop'].
829
Node.js
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, push, push, pop, pop.
class CollStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { CollStack }; const s = new CollStack(); s.push(18); s.push(16); s.push(90); s.push(91); console.log(s.pop()); console.log(s.pop()...
Stack with int elements, ops=['push', 'push', 'push', 'push', 'pop', 'pop'].
830
Node.js
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, push, push, pop, pop.
class CollStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { CollStack }; const s = new CollStack(); s.push(4); s.push(90); s.push(55); s.push(48); console.log(s.pop()); console.log(s.pop())...
Stack with int elements, ops=['push', 'push', 'push', 'push', 'pop', 'pop'].
831
Node.js
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, push, push, pop, pop.
class QStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { QStack }; const s = new QStack(); s.push(85); s.push(75); s.push(10); s.push(62); console.log(s.pop()); console.log(s.pop());
Stack with int elements, ops=['push', 'push', 'push', 'push', 'pop', 'pop'].
832
Node.js
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, push, push, pop, pop.
class QStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { QStack }; const s = new QStack(); s.push(19); s.push(47); s.push(19); s.push(11); console.log(s.pop()); console.log(s.pop());
Stack with int elements, ops=['push', 'push', 'push', 'push', 'pop', 'pop'].
833
Node.js
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, pop, push, push.
class QStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { QStack }; const s = new QStack(); s.push(73); console.log(s.pop()); s.push(20); s.push(98);
Stack with int elements, ops=['push', 'pop', 'push', 'push'].
834
Node.js
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, pop, push, push.
class SStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { SStack }; const s = new SStack(); s.push(61); console.log(s.pop()); s.push(18); s.push(96);
Stack with int elements, ops=['push', 'pop', 'push', 'push'].
835
Node.js
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, pop, push, push.
class ContainerStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { ContainerStack }; const s = new ContainerStack(); s.push(90); console.log(s.pop()); s.push(61); s.push(53);
Stack with int elements, ops=['push', 'pop', 'push', 'push'].
836
Node.js
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, pop, push, push.
class CollStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { CollStack }; const s = new CollStack(); s.push(44); console.log(s.pop()); s.push(83); s.push(89);
Stack with int elements, ops=['push', 'pop', 'push', 'push'].
837
Node.js
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, push, pop.
class QStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { QStack }; const s = new QStack(); s.push(29.39); s.push(16.43); s.push(88.23); console.log(s.pop());
Stack with float elements, ops=['push', 'push', 'push', 'pop'].
838
Node.js
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, push, pop.
class SStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { SStack }; const s = new SStack(); s.push(50.83); s.push(2.08); s.push(83.44); console.log(s.pop());
Stack with float elements, ops=['push', 'push', 'push', 'pop'].
839
Node.js
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, push, pop.
class Box_Stack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { Box_Stack }; const s = new Box_Stack(); s.push(55.86); s.push(83.12); s.push(92.0); console.log(s.pop());
Stack with float elements, ops=['push', 'push', 'push', 'pop'].
840
Node.js
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, push, pop.
class CollStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { CollStack }; const s = new CollStack(); s.push(23.5); s.push(93.21); s.push(27.91); console.log(s.pop());
Stack with float elements, ops=['push', 'push', 'push', 'pop'].
841
Node.js
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, pop, push, pop.
class Box_Stack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { Box_Stack }; const s = new Box_Stack(); s.push(97.81); s.push(13.39); console.log(s.pop()); s.push(62.29); console.log(s.pop());
Stack with float elements, ops=['push', 'push', 'pop', 'push', 'pop'].
842
Node.js
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, pop, push, pop.
class SStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { SStack }; const s = new SStack(); s.push(82.43); s.push(97.62); console.log(s.pop()); s.push(8.64); console.log(s.pop());
Stack with float elements, ops=['push', 'push', 'pop', 'push', 'pop'].
843
Node.js
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, pop, push, pop.
class Box_Stack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { Box_Stack }; const s = new Box_Stack(); s.push(32.01); s.push(64.55); console.log(s.pop()); s.push(17.32); console.log(s.pop());
Stack with float elements, ops=['push', 'push', 'pop', 'push', 'pop'].
844
Node.js
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, pop, push, pop.
class CollStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { CollStack }; const s = new CollStack(); s.push(43.0); s.push(27.72); console.log(s.pop()); s.push(36.91); console.log(s.pop());
Stack with float elements, ops=['push', 'push', 'pop', 'push', 'pop'].
845
Node.js
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, push, push, pop, pop.
class BufStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { BufStack }; const s = new BufStack(); s.push(3.78); s.push(28.94); s.push(54.62); s.push(7.47); console.log(s.pop()); console.log(...
Stack with float elements, ops=['push', 'push', 'push', 'push', 'pop', 'pop'].
846
Node.js
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, push, push, pop, pop.
class BufStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { BufStack }; const s = new BufStack(); s.push(19.59); s.push(20.97); s.push(92.99); s.push(24.79); console.log(s.pop()); console.lo...
Stack with float elements, ops=['push', 'push', 'push', 'push', 'pop', 'pop'].
847
Node.js
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, push, push, pop, pop.
class QStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { QStack }; const s = new QStack(); s.push(56.81); s.push(79.23); s.push(5.52); s.push(32.14); console.log(s.pop()); console.log(s.pop...
Stack with float elements, ops=['push', 'push', 'push', 'push', 'pop', 'pop'].
848
Node.js
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, push, push, pop, pop.
class BufStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { BufStack }; const s = new BufStack(); s.push(75.42); s.push(95.92); s.push(50.52); s.push(32.13); console.log(s.pop()); console.lo...
Stack with float elements, ops=['push', 'push', 'push', 'push', 'pop', 'pop'].
849
Node.js
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, pop, push, push.
class SStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { SStack }; const s = new SStack(); s.push(70.56); console.log(s.pop()); s.push(41.32); s.push(74.4);
Stack with float elements, ops=['push', 'pop', 'push', 'push'].
850
Node.js
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, pop, push, push.
class QStack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { QStack }; const s = new QStack(); s.push(50.72); console.log(s.pop()); s.push(3.34); s.push(79.81);
Stack with float elements, ops=['push', 'pop', 'push', 'push'].
851
Node.js
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, pop, push, push.
class Box_Stack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { Box_Stack }; const s = new Box_Stack(); s.push(59.05); console.log(s.pop()); s.push(29.72); s.push(16.0);
Stack with float elements, ops=['push', 'pop', 'push', 'push'].
852
Node.js
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, pop, push, push.
class Box_Stack { #items = []; push(item) { this.#items.push(item); } pop() { return this.#items.pop(); } peek() { return this.#items[this.#items.length - 1]; } } module.exports = { Box_Stack }; const s = new Box_Stack(); s.push(8.8); console.log(s.pop()); s.push(95.33); s.push(23.93);
Stack with float elements, ops=['push', 'pop', 'push', 'push'].
853
Java
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, push, pop.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Integer> s = new ArrayDeque<>(); s.push(88); s.push(84); s.push(19); System.out.println(s.pop()); } }
Stack with int elements, ops=['push', 'push', 'push', 'pop'].
854
Java
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, push, pop.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Integer> coll = new ArrayDeque<>(); coll.push(21); coll.push(65); coll.push(67); System.out.println(coll.pop()); } }
Stack with int elements, ops=['push', 'push', 'push', 'pop'].
855
Java
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, push, pop.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Integer> container = new ArrayDeque<>(); container.push(84); container.push(67); container.push(99); System.out.println(container.pop()); } }
Stack with int elements, ops=['push', 'push', 'push', 'pop'].
856
Java
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, push, pop.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Integer> box_ = new ArrayDeque<>(); box_.push(17); box_.push(44); box_.push(38); System.out.println(box_.pop()); } }
Stack with int elements, ops=['push', 'push', 'push', 'pop'].
857
Java
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, pop, push, pop.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Integer> container = new ArrayDeque<>(); container.push(56); container.push(6); System.out.println(container.pop()); container.push(100); System.out.println(container.pop()...
Stack with int elements, ops=['push', 'push', 'pop', 'push', 'pop'].
858
Java
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, pop, push, pop.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Integer> box_ = new ArrayDeque<>(); box_.push(31); box_.push(27); System.out.println(box_.pop()); box_.push(78); System.out.println(box_.pop()); } }
Stack with int elements, ops=['push', 'push', 'pop', 'push', 'pop'].
859
Java
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, pop, push, pop.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Integer> s = new ArrayDeque<>(); s.push(73); s.push(81); System.out.println(s.pop()); s.push(13); System.out.println(s.pop()); } }
Stack with int elements, ops=['push', 'push', 'pop', 'push', 'pop'].
860
Java
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, pop, push, pop.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Integer> s = new ArrayDeque<>(); s.push(99); s.push(40); System.out.println(s.pop()); s.push(12); System.out.println(s.pop()); } }
Stack with int elements, ops=['push', 'push', 'pop', 'push', 'pop'].
861
Java
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, push, push, pop, pop.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Integer> q = new ArrayDeque<>(); q.push(59); q.push(41); q.push(22); q.push(38); System.out.println(q.pop()); System.out.println(q.pop()); } }
Stack with int elements, ops=['push', 'push', 'push', 'push', 'pop', 'pop'].
862
Java
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, push, push, pop, pop.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Integer> buf = new ArrayDeque<>(); buf.push(74); buf.push(47); buf.push(46); buf.push(12); System.out.println(buf.pop()); System.out.println(buf.pop()); } }
Stack with int elements, ops=['push', 'push', 'push', 'push', 'pop', 'pop'].
863
Java
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, push, push, pop, pop.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Integer> coll = new ArrayDeque<>(); coll.push(99); coll.push(59); coll.push(34); coll.push(61); System.out.println(coll.pop()); System.out.println(coll.pop()); ...
Stack with int elements, ops=['push', 'push', 'push', 'push', 'pop', 'pop'].
864
Java
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, push, push, pop, pop.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Integer> box_ = new ArrayDeque<>(); box_.push(84); box_.push(18); box_.push(16); box_.push(73); System.out.println(box_.pop()); System.out.println(box_.pop()); ...
Stack with int elements, ops=['push', 'push', 'push', 'push', 'pop', 'pop'].
865
Java
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, pop, push, push.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Integer> buf = new ArrayDeque<>(); buf.push(37); System.out.println(buf.pop()); buf.push(53); buf.push(80); } }
Stack with int elements, ops=['push', 'pop', 'push', 'push'].
866
Java
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, pop, push, push.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Integer> coll = new ArrayDeque<>(); coll.push(17); System.out.println(coll.pop()); coll.push(47); coll.push(66); } }
Stack with int elements, ops=['push', 'pop', 'push', 'push'].
867
Java
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, pop, push, push.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Integer> container = new ArrayDeque<>(); container.push(41); System.out.println(container.pop()); container.push(11); container.push(88); } }
Stack with int elements, ops=['push', 'pop', 'push', 'push'].
868
Java
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, pop, push, push.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Integer> box_ = new ArrayDeque<>(); box_.push(65); System.out.println(box_.pop()); box_.push(34); box_.push(88); } }
Stack with int elements, ops=['push', 'pop', 'push', 'push'].
869
Java
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, push, pop.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Double> q = new ArrayDeque<>(); q.push(62.44); q.push(64.74); q.push(74.36); System.out.println(q.pop()); } }
Stack with float elements, ops=['push', 'push', 'push', 'pop'].
870
Java
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, push, pop.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Double> container = new ArrayDeque<>(); container.push(1.79); container.push(85.45); container.push(29.78); System.out.println(container.pop()); } }
Stack with float elements, ops=['push', 'push', 'push', 'pop'].
871
Java
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, push, pop.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Double> box_ = new ArrayDeque<>(); box_.push(85.53); box_.push(23.08); box_.push(87.54); System.out.println(box_.pop()); } }
Stack with float elements, ops=['push', 'push', 'push', 'pop'].
872
Java
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, push, pop.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Double> buf = new ArrayDeque<>(); buf.push(47.12); buf.push(64.61); buf.push(90.11); System.out.println(buf.pop()); } }
Stack with float elements, ops=['push', 'push', 'push', 'pop'].
873
Java
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, pop, push, pop.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Double> q = new ArrayDeque<>(); q.push(18.85); q.push(11.73); System.out.println(q.pop()); q.push(40.3); System.out.println(q.pop()); } }
Stack with float elements, ops=['push', 'push', 'pop', 'push', 'pop'].
874
Java
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, pop, push, pop.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Double> box_ = new ArrayDeque<>(); box_.push(33.54); box_.push(32.41); System.out.println(box_.pop()); box_.push(49.14); System.out.println(box_.pop()); } }
Stack with float elements, ops=['push', 'push', 'pop', 'push', 'pop'].
875
Java
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, pop, push, pop.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Double> box_ = new ArrayDeque<>(); box_.push(12.32); box_.push(46.0); System.out.println(box_.pop()); box_.push(94.9); System.out.println(box_.pop()); } }
Stack with float elements, ops=['push', 'push', 'pop', 'push', 'pop'].
876
Java
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, pop, push, pop.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Double> s = new ArrayDeque<>(); s.push(32.7); s.push(4.1); System.out.println(s.pop()); s.push(38.65); System.out.println(s.pop()); } }
Stack with float elements, ops=['push', 'push', 'pop', 'push', 'pop'].
877
Java
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, push, push, pop, pop.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Double> buf = new ArrayDeque<>(); buf.push(79.17); buf.push(97.88); buf.push(22.13); buf.push(21.94); System.out.println(buf.pop()); System.out.println(buf.pop()); ...
Stack with float elements, ops=['push', 'push', 'push', 'push', 'pop', 'pop'].
878
Java
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, push, push, pop, pop.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Double> box_ = new ArrayDeque<>(); box_.push(27.71); box_.push(63.93); box_.push(9.28); box_.push(7.86); System.out.println(box_.pop()); System.out.println(box_.pop...
Stack with float elements, ops=['push', 'push', 'push', 'push', 'pop', 'pop'].
879
Java
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, push, push, pop, pop.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Double> coll = new ArrayDeque<>(); coll.push(45.69); coll.push(42.55); coll.push(22.2); coll.push(89.41); System.out.println(coll.pop()); System.out.println(coll.po...
Stack with float elements, ops=['push', 'push', 'push', 'push', 'pop', 'pop'].
880
Java
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, push, push, push, pop, pop.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Double> box_ = new ArrayDeque<>(); box_.push(34.86); box_.push(75.56); box_.push(17.29); box_.push(35.58); System.out.println(box_.pop()); System.out.println(box_.p...
Stack with float elements, ops=['push', 'push', 'push', 'push', 'pop', 'pop'].
881
Java
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, pop, push, push.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Double> coll = new ArrayDeque<>(); coll.push(78.6); System.out.println(coll.pop()); coll.push(44.24); coll.push(91.35); } }
Stack with float elements, ops=['push', 'pop', 'push', 'push'].
882
Java
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, pop, push, push.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Double> container = new ArrayDeque<>(); container.push(39.52); System.out.println(container.pop()); container.push(78.52); container.push(60.12); } }
Stack with float elements, ops=['push', 'pop', 'push', 'push'].
883
Java
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, pop, push, push.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Double> q = new ArrayDeque<>(); q.push(72.55); System.out.println(q.pop()); q.push(15.32); q.push(66.74); } }
Stack with float elements, ops=['push', 'pop', 'push', 'push'].
884
Java
Data Structures
intermediate
Implement a stack of floats and run the operation sequence: push, pop, push, push.
import java.util.*; public class Main { public static void main(String[] args) { Deque<Double> coll = new ArrayDeque<>(); coll.push(74.54); System.out.println(coll.pop()); coll.push(32.34); coll.push(15.9); } }
Stack with float elements, ops=['push', 'pop', 'push', 'push'].
885
C
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, push, pop.
#include <stdio.h> #define MAX 100 typedef struct { int items[MAX]; int top; } Stack; void push(Stack* s, int value) { s->items[++s->top] = value; } int pop(Stack* s) { return s->items[s->top--]; } int main(void) { Stack box_ = { .top = -1 }; push(&box_, 19); push(&box_, 64); push(&box_, 41); ...
Stack with int elements, ops=['push', 'push', 'push', 'pop'].
886
C
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, push, pop.
#include <stdio.h> #define MAX 100 typedef struct { int items[MAX]; int top; } Stack; void push(Stack* s, int value) { s->items[++s->top] = value; } int pop(Stack* s) { return s->items[s->top--]; } int main(void) { Stack coll = { .top = -1 }; push(&coll, 53); push(&coll, 34); push(&coll, 67); ...
Stack with int elements, ops=['push', 'push', 'push', 'pop'].
887
C
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, push, pop.
#include <stdio.h> #define MAX 100 typedef struct { int items[MAX]; int top; } Stack; void push(Stack* s, int value) { s->items[++s->top] = value; } int pop(Stack* s) { return s->items[s->top--]; } int main(void) { Stack q = { .top = -1 }; push(&q, 58); push(&q, 17); push(&q, 82); printf("%g\...
Stack with int elements, ops=['push', 'push', 'push', 'pop'].
888
C
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, push, pop.
#include <stdio.h> #define MAX 100 typedef struct { int items[MAX]; int top; } Stack; void push(Stack* s, int value) { s->items[++s->top] = value; } int pop(Stack* s) { return s->items[s->top--]; } int main(void) { Stack coll = { .top = -1 }; push(&coll, 75); push(&coll, 13); push(&coll, 5); ...
Stack with int elements, ops=['push', 'push', 'push', 'pop'].
889
C
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, pop, push, pop.
#include <stdio.h> #define MAX 100 typedef struct { int items[MAX]; int top; } Stack; void push(Stack* s, int value) { s->items[++s->top] = value; } int pop(Stack* s) { return s->items[s->top--]; } int main(void) { Stack coll = { .top = -1 }; push(&coll, 25); push(&coll, 54); printf("%g\n", (doub...
Stack with int elements, ops=['push', 'push', 'pop', 'push', 'pop'].
890
C
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, pop, push, pop.
#include <stdio.h> #define MAX 100 typedef struct { int items[MAX]; int top; } Stack; void push(Stack* s, int value) { s->items[++s->top] = value; } int pop(Stack* s) { return s->items[s->top--]; } int main(void) { Stack s = { .top = -1 }; push(&s, 77); push(&s, 49); printf("%g\n", (double)pop(&s...
Stack with int elements, ops=['push', 'push', 'pop', 'push', 'pop'].
891
C
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, pop, push, pop.
#include <stdio.h> #define MAX 100 typedef struct { int items[MAX]; int top; } Stack; void push(Stack* s, int value) { s->items[++s->top] = value; } int pop(Stack* s) { return s->items[s->top--]; } int main(void) { Stack s = { .top = -1 }; push(&s, 87); push(&s, 74); printf("%g\n", (double)pop(&s...
Stack with int elements, ops=['push', 'push', 'pop', 'push', 'pop'].
892
C
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, pop, push, pop.
#include <stdio.h> #define MAX 100 typedef struct { int items[MAX]; int top; } Stack; void push(Stack* s, int value) { s->items[++s->top] = value; } int pop(Stack* s) { return s->items[s->top--]; } int main(void) { Stack q = { .top = -1 }; push(&q, 39); push(&q, 40); printf("%g\n", (double)pop(&q...
Stack with int elements, ops=['push', 'push', 'pop', 'push', 'pop'].
893
C
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, push, push, pop, pop.
#include <stdio.h> #define MAX 100 typedef struct { int items[MAX]; int top; } Stack; void push(Stack* s, int value) { s->items[++s->top] = value; } int pop(Stack* s) { return s->items[s->top--]; } int main(void) { Stack box_ = { .top = -1 }; push(&box_, 84); push(&box_, 59); push(&box_, 53); ...
Stack with int elements, ops=['push', 'push', 'push', 'push', 'pop', 'pop'].
894
C
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, push, push, pop, pop.
#include <stdio.h> #define MAX 100 typedef struct { int items[MAX]; int top; } Stack; void push(Stack* s, int value) { s->items[++s->top] = value; } int pop(Stack* s) { return s->items[s->top--]; } int main(void) { Stack container = { .top = -1 }; push(&container, 55); push(&container, 67); push(...
Stack with int elements, ops=['push', 'push', 'push', 'push', 'pop', 'pop'].
895
C
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, push, push, pop, pop.
#include <stdio.h> #define MAX 100 typedef struct { int items[MAX]; int top; } Stack; void push(Stack* s, int value) { s->items[++s->top] = value; } int pop(Stack* s) { return s->items[s->top--]; } int main(void) { Stack box_ = { .top = -1 }; push(&box_, 55); push(&box_, 48); push(&box_, 23); ...
Stack with int elements, ops=['push', 'push', 'push', 'push', 'pop', 'pop'].
896
C
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, push, push, push, pop, pop.
#include <stdio.h> #define MAX 100 typedef struct { int items[MAX]; int top; } Stack; void push(Stack* s, int value) { s->items[++s->top] = value; } int pop(Stack* s) { return s->items[s->top--]; } int main(void) { Stack container = { .top = -1 }; push(&container, 56); push(&container, 49); push(...
Stack with int elements, ops=['push', 'push', 'push', 'push', 'pop', 'pop'].
897
C
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, pop, push, push.
#include <stdio.h> #define MAX 100 typedef struct { int items[MAX]; int top; } Stack; void push(Stack* s, int value) { s->items[++s->top] = value; } int pop(Stack* s) { return s->items[s->top--]; } int main(void) { Stack box_ = { .top = -1 }; push(&box_, 82); printf("%g\n", (double)pop(&box_)); p...
Stack with int elements, ops=['push', 'pop', 'push', 'push'].
898
C
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, pop, push, push.
#include <stdio.h> #define MAX 100 typedef struct { int items[MAX]; int top; } Stack; void push(Stack* s, int value) { s->items[++s->top] = value; } int pop(Stack* s) { return s->items[s->top--]; } int main(void) { Stack q = { .top = -1 }; push(&q, 12); printf("%g\n", (double)pop(&q)); push(&q, 1...
Stack with int elements, ops=['push', 'pop', 'push', 'push'].
899
C
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, pop, push, push.
#include <stdio.h> #define MAX 100 typedef struct { int items[MAX]; int top; } Stack; void push(Stack* s, int value) { s->items[++s->top] = value; } int pop(Stack* s) { return s->items[s->top--]; } int main(void) { Stack q = { .top = -1 }; push(&q, 79); printf("%g\n", (double)pop(&q)); push(&q, 1...
Stack with int elements, ops=['push', 'pop', 'push', 'push'].
900
C
Data Structures
intermediate
Implement a stack of ints and run the operation sequence: push, pop, push, push.
#include <stdio.h> #define MAX 100 typedef struct { int items[MAX]; int top; } Stack; void push(Stack* s, int value) { s->items[++s->top] = value; } int pop(Stack* s) { return s->items[s->top--]; } int main(void) { Stack coll = { .top = -1 }; push(&coll, 97); printf("%g\n", (double)pop(&coll)); p...
Stack with int elements, ops=['push', 'pop', 'push', 'push'].