Skip to content

Instantly share code, notes, and snippets.

View fortunee's full-sized avatar
🎯
Focusing

Fortune Ekeruo fortunee

🎯
Focusing
View GitHub Profile
@fortunee
fortunee / queue.js
Created March 25, 2023 00:48
Queue
class Node {
constructor(value) {
this.value = value;
this.next = null;
}
}
class Queue {
constructor() {
this.size = 0;
@fortunee
fortunee / fib.js
Created March 25, 2023 00:50
Fibonacci sequence
function fib(num){
if (num <= 2) return 1;
return fib(num - 1) + fib(num - 2);
}
fib(4);