/leetcode

Solved leetcode problems using Prolog and Haskell

Primary LanguageHaskellGNU General Public License v3.0GPL-3.0

My solutions for leetcode problems

I've started solving some leetcode problems with a goal to improve in Prolog and Haskell. Unfortunately leetcode doesn't support neither of these languages and probably will never support Prolog, so I can't check whether my solution would be accepted.

Easy

# Name File

Medium

# Name File
15 3Sum n_sum.pl
16 3Sum Closest n_sum.pl
17 Letter Combinations of a Phone Number letter_combinations.pl
18 4Sum n_sum.pl
22 Generate Parentheses generate_parentheses.hs
39 Combination Sum combination_sum_i_ii.pl
40 Combination Sum II combination_sum_i_ii.pl
47 Permutations II permutations_ii.hs
48 Rotate Image rotate_image.hs
49 Group Anagrams group_anagrams.pl
55 Jump Game jump_game_i_ii.hs
71 Simplify Path unix_path_simplifier.hs
78 Subsets subsets_i_ii.pl
90 Subsets II subsets_i_ii.pl
93 Restore IP Addresses restore_ip_addresses.pl
95 Unique Binary Search Trees II unique_bsts_i_ii.pl
96 Unique Binary Search Trees unique_bsts_i_ii.pl
98 Validate Binary Search Tree validate_bst.pl
179 Largest Number largest_number.hs
187 Repeated DNA Sequences repeated_dna_seq.hs
670 Maximum Swap maximum_swap.hs
921 Minimum Add to Make Parentheses Valid parentheses_valid_changes_count.hs

Hard

# Name File
4 Median of Two Sorted Arrays median_of_two_sorted_arrays.hs
32 Longest Valid Parentheses longest_valid_parentheses.hs
45 Jump Game II jump_game_i_ii.hs
87 Scramble String scramble_string.hs