Craig's public fiddles
-
vokjyL4r
No-Library (pure JS), HTML, CSS, JavaScript
-
Last Stone Weight
No-Library (pure JS), HTML, CSS, JavaScript
-
qphaxsoy
No-Library (pure JS), HTML, CSS, JavaScript
-
Min Stack
No-Library (pure JS), HTML, CSS, JavaScript
-
62tkhscr
No-Library (pure JS), HTML, CSS, JavaScript
-
Backspace String Compare
No-Library (pure JS), HTML, CSS, JavaScript
-
Middle of the Linked List
Given a non-empty, singly linked list with head node head, return a middle node of linked list. If there are two middle nodes, return the second middle node.
-
Set
No-Library (pure JS), HTML, CSS, JavaScript
-
Counting Elements
Given an integer array arr, count element x such that x + 1 is also in arr. If there're duplicates in arr, count them separately.
-
Group Anagrams
Given an array of strings, group anagrams together.
-
Maps and Weak Maps
No-Library (pure JS), HTML, CSS, JavaScript
-
Buy and sell
You may not engage in multiple transactions at the same time (i.e., you must sell the stock before you buy again).
-
Move Zeros
Given an array nums, write a function to move all 0's to the end of it while maintaining the relative order of the non-zero elements.
-
Maximum Subarray
Given an integer array nums, find the contiguous subarray (containing at least one number) which has the largest sum and return its sum.
-
ntwr5ks4
No-Library (pure JS), HTML, CSS, JavaScript
-
Happy Number
Write an algorithm to determine if a number is "happy".
-
Destructuring
No-Library (pure JS), HTML, CSS, JavaScript
-
Single Number
Given a non-empty array of integers, every element appears twice except for one. Find that single one.
-
Rest & Spread
No-Library (pure JS), HTML, CSS, JavaScript
-
Tagged Templates
No-Library (pure JS), HTML, CSS, JavaScript