From cb0f5906fdf7a22a097958cbb89783905baf970f Mon Sep 17 00:00:00 2001 From: Steve2020 <841532108@qq.com> Date: Sat, 8 Jan 2022 23:55:34 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=EF=BC=88=E9=93=BE=E8=A1=A8?= =?UTF-8?q?=E7=90=86=E8=AE=BA=E5=9F=BA=E7=A1=80.md=EF=BC=89=EF=BC=9A?= =?UTF-8?q?=E5=A2=9E=E5=8A=A0JS=E5=92=8CTS=E7=89=88=E6=9C=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- problems/链表理论基础.md | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/problems/链表理论基础.md b/problems/链表理论基础.md index 02b7029e..109aa1ed 100644 --- a/problems/链表理论基础.md +++ b/problems/链表理论基础.md @@ -168,6 +168,32 @@ public class ListNode { } ``` +JavaScript: + +```javascript +class ListNode { + val; + next = null; + constructor(value) { + this.val = value; + this.next = null; + } +} +``` + +TypeScript: + +```typescript +class ListNode { + public val: number; + public next: ListNode = null; + constructor(value: number) { + this.val = value; + this.next = null; + } +} +``` + Python: