MCPcopy Create free account
hub / github.com/ashishps1/awesome-leetcode-resources / ListNode

Class ListNode

patterns/javascript/reverseList.js:1–6  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1class ListNode {
2 constructor(val = 0, next = null) {
3 this.val = val;
4 this.next = next;
5 }
6}
7
8function reverseList(head) {
9 let prev = null;

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected