<commit_before>linkedListCycle.js<commit_msg>add desc<commit_after>// Given a linked list, determine if it has a cycle in it.

// which would return true if the given Node is the first of a list with a loop, and false otherwise?
// How could you write so that it takes a constant amount of space and a reasonable amount of time?

// Here's a picture of what a list with a loop looks like:

// 1 -> 2 -> 3-> 4 -> 5 -> 6 -> 3

/**
 * Definition for singly-linked list.
 * function ListNode(val) {
 *     this.val = val;
 *     this.next = null;
 * }
 */

/**
 * @param {ListNode} head
 * @return {boolean}
 */


{'fraction_non_alphanumeric': 0.11658456486042693, 'fraction_numerical': 0.011494252873563218, 'mean_word_length': 2.7888198757763973, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6804632', 'n_tokens_mistral': 195, 'n_tokens_neox': 185, 'n_words': 87}