<commit_before>quicksort :: (Ord a) => [a] -> [a]
quicksort [] = []
quicksort (x:xs) = smallerSorted ++ [x] ++ biggerSorted
  where smallerSorted = quicksort [a | a <- xs, a <= x]
        biggerSorted = quicksort [a | a <- xs, a > x] <commit_msg>binarySearch<commit_after>quicksort :: (Ord a) => [a] -> [a]
quicksort [] = []
quicksort (x:xs) = smallerSorted ++ [x] ++ biggerSorted
  where smallerSorted = quicksort [a | a <- xs, a <= x]
        biggerSorted = quicksort [a | a <- xs, a > x] 

-- ش Ұ ִ ġ 
binarySearch :: (Ord a) => a -> [a] -> Int -> Int -> Int
binarySearch _ [] _ _ = -1
binarySearch x xs f l
		| f > l = (-1)
		| x == element = m
		| x > element = binarySearch x xs (m+1) l
		| x <= element = binarySearch x xs f (m-1)
  where m = (f + l) `div` 2
        element = xs !! m
{'fraction_non_alphanumeric': 0.18836915297092288, 'fraction_numerical': 0.006321112515802781, 'mean_word_length': 2.63302752293578, 'pattern_counts': {'":': 0, '<': 10, '<?xml version=': 0, '>': 16, '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': '2427859', 'n_tokens_mistral': 325, 'n_tokens_neox': 312, 'n_words': 100}