使用set保存已遍历过的节点,遇到一样的,即为入口节点 /*function ListNode(x){ this.val = x; this.next = null; }*/ function EntryNodeOfLoop(pHead) { // write code here const set = new Set(); while(pHead.next!=null){ if(set.has(pHead)){ return pHead; } console.log(pHead);...