DatasetRepo commited on
Commit
c1a3802
·
verified ·
1 Parent(s): 9ec8ded

9d278973e453cde681bddd7e6d18cf26ffaf0f9dcf031dd782900e43f3236f28

Browse files
This view is limited to 50 files because it contains too many changes.   See raw diff
Files changed (50) hide show
  1. .gitattributes +1 -0
  2. count_alternating_subarrays/java_tests/Main.java +20 -0
  3. count_alternating_subarrays/meta.json +0 -0
  4. count_alternating_subarrays/ocaml_tests/main.ml +0 -0
  5. count_alternating_subarrays/scala_tests/MySuite.scala +0 -0
  6. count_anagrams/.DS_Store +0 -0
  7. count_anagrams/haskell_tests/Main.hs +24 -0
  8. count_anagrams/java_tests/Main.java +21 -0
  9. count_anagrams/meta.json +67 -0
  10. count_anagrams/ocaml_tests/main.ml +26 -0
  11. count_anagrams/scala_tests/MySuite.scala +12 -0
  12. count_array_pairs_divisible_by_k/.DS_Store +0 -0
  13. count_array_pairs_divisible_by_k/haskell_tests/Main.hs +24 -0
  14. count_array_pairs_divisible_by_k/java_tests/Main.java +21 -0
  15. count_array_pairs_divisible_by_k/meta.json +3 -0
  16. count_array_pairs_divisible_by_k/ocaml_tests/main.ml +26 -0
  17. count_array_pairs_divisible_by_k/scala_tests/MySuite.scala +12 -0
  18. count_asterisks/haskell_tests/Main.hs +47 -0
  19. count_asterisks/java_tests/Main.java +24 -0
  20. count_asterisks/meta.json +72 -0
  21. count_asterisks/ocaml_tests/main.ml +51 -0
  22. count_asterisks/scala_tests/MySuite.scala +44 -0
  23. count_beautiful_numbers/haskell_tests/Main.hs +45 -0
  24. count_beautiful_numbers/java_tests/Main.java +21 -0
  25. count_beautiful_numbers/meta.json +97 -0
  26. count_beautiful_numbers/ocaml_tests/main.ml +50 -0
  27. count_beautiful_numbers/scala_tests/MySuite.scala +44 -0
  28. count_beautiful_splits_in_an_array/haskell_tests/Main.hs +0 -0
  29. count_beautiful_splits_in_an_array/java_tests/Main.java +20 -0
  30. count_beautiful_splits_in_an_array/meta.json +0 -0
  31. count_beautiful_splits_in_an_array/ocaml_tests/main.ml +42 -0
  32. count_beautiful_splits_in_an_array/scala_tests/MySuite.scala +32 -0
  33. count_beautiful_substrings_i/haskell_tests/Main.hs +45 -0
  34. count_beautiful_substrings_i/java_tests/Main.java +25 -0
  35. count_beautiful_substrings_i/meta.json +102 -0
  36. count_beautiful_substrings_i/ocaml_tests/main.ml +50 -0
  37. count_beautiful_substrings_i/scala_tests/MySuite.scala +44 -0
  38. count_beautiful_substrings_ii/haskell_tests/Main.hs +0 -0
  39. count_beautiful_substrings_ii/java_tests/Main.java +25 -0
  40. count_beautiful_substrings_ii/meta.json +0 -0
  41. count_beautiful_substrings_ii/ocaml_tests/main.ml +0 -0
  42. count_beautiful_substrings_ii/scala_tests/MySuite.scala +0 -0
  43. count_collisions_on_a_road/.DS_Store +0 -0
  44. count_collisions_on_a_road/haskell_tests/Main.hs +24 -0
  45. count_collisions_on_a_road/java_tests/Main.java +21 -0
  46. count_collisions_on_a_road/meta.json +0 -0
  47. count_collisions_on_a_road/ocaml_tests/main.ml +26 -0
  48. count_collisions_on_a_road/scala_tests/MySuite.scala +12 -0
  49. count_complete_subarrays_in_an_array/haskell_tests/Main.hs +41 -0
  50. count_complete_subarrays_in_an_array/java_tests/Main.java +20 -0
.gitattributes CHANGED
@@ -73,3 +73,4 @@ check_if_grid_can_be_cut_into_sections/ocaml_tests/main.ml filter=lfs diff=lfs m
73
  check_if_grid_can_be_cut_into_sections/scala_tests/MySuite.scala filter=lfs diff=lfs merge=lfs -text
74
  closest_equal_element_queries/meta.json filter=lfs diff=lfs merge=lfs -text
75
  collect_coins_in_a_tree/meta.json filter=lfs diff=lfs merge=lfs -text
 
 
73
  check_if_grid_can_be_cut_into_sections/scala_tests/MySuite.scala filter=lfs diff=lfs merge=lfs -text
74
  closest_equal_element_queries/meta.json filter=lfs diff=lfs merge=lfs -text
75
  collect_coins_in_a_tree/meta.json filter=lfs diff=lfs merge=lfs -text
76
+ count_array_pairs_divisible_by_k/meta.json filter=lfs diff=lfs merge=lfs -text
count_alternating_subarrays/java_tests/Main.java ADDED
@@ -0,0 +1,20 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ import static org.junit.jupiter.api.Assertions.*;
3
+ import org.junit.jupiter.api.Test;
4
+ import java.util.List;
5
+ import java.util.Arrays;
6
+ public class Main {
7
+ //Program start
8
+
9
+ //Program end
10
+
11
+ @Test
12
+ public void test1() {
13
+ assertEquals(5, countAlternatingSubarrays(Arrays.asList(0,1,1,1)));
14
+ }
15
+ @Test
16
+ public void test2() {
17
+ assertEquals(10, countAlternatingSubarrays(Arrays.asList(1,0,1,0)));
18
+ }
19
+
20
+ }
count_alternating_subarrays/meta.json ADDED
The diff for this file is too large to render. See raw diff
 
count_alternating_subarrays/ocaml_tests/main.ml ADDED
The diff for this file is too large to render. See raw diff
 
count_alternating_subarrays/scala_tests/MySuite.scala ADDED
The diff for this file is too large to render. See raw diff
 
count_anagrams/.DS_Store ADDED
Binary file (6.15 kB). View file
 
count_anagrams/haskell_tests/Main.hs ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ module Main where
3
+ import Test.HUnit
4
+
5
+ --Program start
6
+
7
+ --Program end
8
+
9
+ -- Test cases
10
+
11
+ test1 :: Test
12
+ test1 = TestCase (assertEqual "for (countAnagrams \"too hot \")," 18 (countAnagrams "too hot"))
13
+
14
+ test2 :: Test
15
+ test2 = TestCase (assertEqual "for (countAnagrams \"aa \")," 1 (countAnagrams "aa"))
16
+
17
+
18
+ -- Grouping test cases
19
+ tests :: Test
20
+ tests = TestList [TestLabel "Test1" test1]
21
+
22
+ -- Running the tests
23
+ main :: IO Counts
24
+ main = runTestTT tests
count_anagrams/java_tests/Main.java ADDED
@@ -0,0 +1,21 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ import static org.junit.jupiter.api.Assertions.*;
3
+ import org.junit.jupiter.api.Test;
4
+ import java.util.List;
5
+ import java.util.Arrays;
6
+ import java.util.ArrayList;
7
+ public class Main {
8
+ //Program start
9
+
10
+ //Program end
11
+
12
+ @Test
13
+ public void test1() {
14
+ assertEquals(18, countAnagrams("too hot"));
15
+ }
16
+ @Test
17
+ public void test2() {
18
+ assertEquals(1, countAnagrams("aa"));
19
+ }
20
+
21
+ }
count_anagrams/meta.json ADDED
@@ -0,0 +1,67 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "id": 2605,
3
+ "name": "count_anagrams",
4
+ "difficulty": "Hard",
5
+ "link": "https://leetcode.com/problems/count-anagrams/",
6
+ "date": "1670630400000",
7
+ "task_description": "You are given a string `s` containing one or more words. Every consecutive pair of words is separated by a single space `' '`. A string `t` is an **anagram** of string `s` if the `ith` word of `t` is a **permutation** of the `ith` word of `s`. For example, `\"acb dfe\"` is an anagram of `\"abc def\"`, but `\"def cab\"` and `\"adc bef\"` are not. Return _the number of **distinct anagrams** of _`s`. Since the answer may be very large, return it **modulo** `109 + 7`. **Example 1:** ``` **Input:** s = \"too hot\" **Output:** 18 **Explanation:** Some of the anagrams of the given string are \"too hot\", \"oot hot\", \"oto toh\", \"too toh\", and \"too oht\". ``` **Example 2:** ``` **Input:** s = \"aa\" **Output:** 1 **Explanation:** There is only one anagram possible for the given string. ``` **Constraints:** `1 <= s.length <= 105` `s` consists of lowercase English letters and spaces `' '`. There is single space between consecutive words.",
8
+ "public_test_cases": [
9
+ {
10
+ "label": "Example 1",
11
+ "input": "s = \"too hot\"",
12
+ "output": "18 "
13
+ },
14
+ {
15
+ "label": "Example 2",
16
+ "input": "s = \"aa\"",
17
+ "output": "1 "
18
+ }
19
+ ],
20
+ "private_test_cases": [
21
+ {
22
+ "input": "exwwd h g gwjah dkenzm lsefdbx",
23
+ "output": 127359818
24
+ },
25
+ {
26
+ "input": "xiadu hhjwznshpu vgwwdci jetkdx bjda wygzeaybnjpitadeums zbvtbxbqoiincarawwfpcjipcdhkoxwiyilextnjuhyckdmswktsgalblbfyvmmkdbqtpxjfi",
27
+ "output": 476389245
28
+ },
29
+ {
30
+ "input": "kapz myr gcax",
31
+ "output": 3456
32
+ },
33
+ {
34
+ "input": "tqyk bwkylasc oybtknjyoodhelqcculospnzpzeibo",
35
+ "output": 944886382
36
+ },
37
+ {
38
+ "input": "dipsap eocmc",
39
+ "output": 21600
40
+ },
41
+ {
42
+ "input": "mn xshpnx dn b dlzk xixdqmca p t kcmfefqrfdoirwbjvvup a",
43
+ "output": 109579872
44
+ },
45
+ {
46
+ "input": "vy pmqfigu vg lbkloix xn yamzxseeprrpp jrpijwnhynr hjvuyuefqtrxdczknkwfsn iwliazsyrmwrflizgula zbabmlpqkaduustmuqjtahrfeqeihbtzpbiuquxmvfght",
47
+ "output": 417088864
48
+ },
49
+ {
50
+ "input": "ltuj hqylb vid hfgeluu jysc xvxj szdcnmcadicay j ibrqlonyqwexulunbpvxlhzl",
51
+ "output": 383006897
52
+ },
53
+ {
54
+ "input": "kzmnek hsxodpqun yuctdeurewrddtnzptxkevedjeypbgbjx qjgxtkxbqwgalvccxaxeeumzhieebwzvwpsibuvuzhosegoioz",
55
+ "output": 769510011
56
+ },
57
+ {
58
+ "input": "kz sxkqe fqy rmzafbkn urws scenuqlwsgh tavvftekhlguvs cgspkvfgdepxfvcmgnqbhoicn xnivooeorwtejhdjujaz",
59
+ "output": 807141157
60
+ }
61
+ ],
62
+ "haskell_template": "countAnagrams :: String -> Int\ncountAnagrams s ",
63
+ "ocaml_template": "let countAnagrams (s: string) : int = ",
64
+ "scala_template": "def countAnagrams(s: String): Int = { \n \n}",
65
+ "java_template": "public static int countAnagrams(String s) {\n\n}",
66
+ "python_template": "class Solution(object):\n def countAnagrams(self, s):\n \"\"\"\n :type s: str\n :rtype: int\n \"\"\"\n "
67
+ }
count_anagrams/ocaml_tests/main.ml ADDED
@@ -0,0 +1,26 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ module Main = struct
3
+ open OUnit2
4
+
5
+ (* Program start *)
6
+
7
+ (* Program end *)
8
+
9
+ (* Test cases *)
10
+
11
+ let test1 _ = assert_equal 18 (countAnagrams "too hot")
12
+
13
+ let test2 _ = assert_equal 1 (countAnagrams "aa")
14
+
15
+
16
+ (* Grouping test cases *)
17
+ let suite = "Test Suite for countAnagrams" >::: [
18
+
19
+ "test1" >:: test1;
20
+ "test2" >:: test2;
21
+ ]
22
+
23
+
24
+ (* Running the tests *)
25
+ let () = run_test_tt_main suite
26
+ end
count_anagrams/scala_tests/MySuite.scala ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ class MySuite extends munit.FunSuite {
3
+
4
+ test("test1") {
5
+ assertEquals(Main.countAnagrams("too hot"), 18)
6
+ }
7
+
8
+ test("test2") {
9
+ assertEquals(Main.countAnagrams("aa"), 1)
10
+ }
11
+
12
+ }
count_array_pairs_divisible_by_k/.DS_Store ADDED
Binary file (6.15 kB). View file
 
count_array_pairs_divisible_by_k/haskell_tests/Main.hs ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ module Main where
3
+ import Test.HUnit
4
+
5
+ --Program start
6
+
7
+ --Program end
8
+
9
+ -- Test cases
10
+
11
+ test1 :: Test
12
+ test1 = TestCase (assertEqual "for (countPairs [1,2,3,4,5] 2)," 7 (countPairs [1,2,3,4,5] 2))
13
+
14
+ test2 :: Test
15
+ test2 = TestCase (assertEqual "for (countPairs [1,2,3,4] 5)," 0 (countPairs [1,2,3,4] 5))
16
+
17
+
18
+ -- Grouping test cases
19
+ tests :: Test
20
+ tests = TestList [TestLabel "Test1" test1]
21
+
22
+ -- Running the tests
23
+ main :: IO Counts
24
+ main = runTestTT tests
count_array_pairs_divisible_by_k/java_tests/Main.java ADDED
@@ -0,0 +1,21 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ import static org.junit.jupiter.api.Assertions.*;
3
+ import org.junit.jupiter.api.Test;
4
+ import java.util.List;
5
+ import java.util.Arrays;
6
+ import java.util.ArrayList;
7
+ public class Main {
8
+ //Program start
9
+
10
+ //Program end
11
+
12
+ @Test
13
+ public void test1() {
14
+ assertEquals(7, countPairs(new ArrayList<>(Arrays.asList(1,2,3,4,5)), 2));
15
+ }
16
+ @Test
17
+ public void test2() {
18
+ assertEquals(0, countPairs(new ArrayList<>(Arrays.asList(1,2,3,4)), 5));
19
+ }
20
+
21
+ }
count_array_pairs_divisible_by_k/meta.json ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:471865dfd300c085eb76d3b3ffaebec5e6e369fedbb3e9c6be78011651d23ae0
3
+ size 13511289
count_array_pairs_divisible_by_k/ocaml_tests/main.ml ADDED
@@ -0,0 +1,26 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ module Main = struct
3
+ open OUnit2
4
+
5
+ (* Program start *)
6
+
7
+ (* Program end *)
8
+
9
+ (* Test cases *)
10
+
11
+ let test1 _ = assert_equal 7 (countPairs [1;2;3;4;5] 2)
12
+
13
+ let test2 _ = assert_equal 0 (countPairs [1;2;3;4] 5)
14
+
15
+
16
+ (* Grouping test cases *)
17
+ let suite = "Test Suite for countPairs" >::: [
18
+
19
+ "test1" >:: test1;
20
+ "test2" >:: test2;
21
+ ]
22
+
23
+
24
+ (* Running the tests *)
25
+ let () = run_test_tt_main suite
26
+ end
count_array_pairs_divisible_by_k/scala_tests/MySuite.scala ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ class MySuite extends munit.FunSuite {
3
+
4
+ test("test1") {
5
+ assertEquals(Main.countPairs(List(1,2,3,4,5),2), 7)
6
+ }
7
+
8
+ test("test2") {
9
+ assertEquals(Main.countPairs(List(1,2,3,4),5), 0)
10
+ }
11
+
12
+ }
count_asterisks/haskell_tests/Main.hs ADDED
@@ -0,0 +1,47 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ module Main where
3
+ import Test.HUnit
4
+
5
+ --Program start
6
+ countAsterisks :: String -> Int
7
+ countAsterisks s = undefined
8
+
9
+ --Program end
10
+
11
+ -- Test cases
12
+
13
+ test1 :: Test
14
+ test1 = TestCase (assertEqual "for (countAsterisks \"l|*e*et|c**o|*de| \")," 2 (countAsterisks "l|*e*et|c**o|*de|"))
15
+
16
+ test2 :: Test
17
+ test2 = TestCase (assertEqual "for (countAsterisks \"iamprogrammer \")," 0 (countAsterisks "iamprogrammer"))
18
+
19
+ test3 :: Test
20
+ test3 = TestCase (assertEqual "for (countAsterisks \"yo|uar|e**|b|e***au|tifu|l \")," 5 (countAsterisks "yo|uar|e**|b|e***au|tifu|l"))
21
+
22
+ test4 :: Test
23
+ test4 = TestCase (assertEqual "for (countAsterisks \"d|ow|gk|lzdd||sa|xrf|tcym|qpzsef|uzobo*|rdua|r||wwqxvvu|eyihm||g|||p|iudapolatiquzrd|qeu|ohf||unpll|n|u|yf||vgd|||aa|np|c|*|udodphvim|cbamtp|*|kigfprbxi|yfhobt|hwe|i|j||pfovtcr|by|jv*ggokksuxu|p|ebmnp|eb|*qe|upsfczfdd|ft||a|pyuccepcind||fq|kxtgtcsfdjgxltmwp*cgc||nlnlvo|n|cepsrrbvyyarbv|xkv||re|irn*|roo|bohls|enfdnzybipcv||y|c|b|so||j|f \")," 1 (countAsterisks "d|ow|gk|lzdd||sa|xrf|tcym|qpzsef|uzobo*|rdua|r||wwqxvvu|eyihm||g|||p|iudapolatiquzrd|qeu|ohf||unpll|n|u|yf||vgd|||aa|np|c|*|udodphvim|cbamtp|*|kigfprbxi|yfhobt|hwe|i|j||pfovtcr|by|jv*ggokksuxu|p|ebmnp|eb|*qe|upsfczfdd|ft||a|pyuccepcind||fq|kxtgtcsfdjgxltmwp*cgc||nlnlvo|n|cepsrrbvyyarbv|xkv||re|irn*|roo|bohls|enfdnzybipcv||y|c|b|so||j|f"))
24
+
25
+ test5 :: Test
26
+ test5 = TestCase (assertEqual "for (countAsterisks \"vmkvy|ivfli|mepdn||qkd|z*cu|gtffodgjiyx|k|xjhpd|klzqm|xwflc|i||ar|*wwdj*i|vcy|myd*g|kp|u|||gr|||sa|dq|l|ygcy|i|ehcu|k||f|zb||y||o|eb|hgn||zi*|trn|f||acnlzkxvj||q||rompz|lfu|||lj|ko*|mjvq||p|m|g||||z||eefkydx||msqg|nq|mp*ft*|hmc|sbccmsh|fbf|ltr|ufk||u|wibcpucdkuh*w||f|fpv|wmty|xhbb|e|tl||trbuh|ycp|ezxwmexdk*hueq|rfqi|rehmiyvjdngde|mojjgoc|f|e|dfu|lbr||cl*|*|qadmqx|fo|||uenosrkwcddsahyln|mh||sta|qrgoaivyio*y*s||||ercwmvl|l|h||pb|omftz|cy|xsy|sg|v|kwy|oh|kbjsfv*|gqb|yii*thh|xqr||ejrpy*|phcx|fe|uip*|qede||sgygkiqq|i|yli|ett|brsl|z|gpn|jmpl|zy|||vklt|ygjqr|ebjm||oozbmusw||gj|dluvhcxtk|j|pw|mgr|qozvcu|gnp|jn|dtiqryn|phkrn \")," 7 (countAsterisks "vmkvy|ivfli|mepdn||qkd|z*cu|gtffodgjiyx|k|xjhpd|klzqm|xwflc|i||ar|*wwdj*i|vcy|myd*g|kp|u|||gr|||sa|dq|l|ygcy|i|ehcu|k||f|zb||y||o|eb|hgn||zi*|trn|f||acnlzkxvj||q||rompz|lfu|||lj|ko*|mjvq||p|m|g||||z||eefkydx||msqg|nq|mp*ft*|hmc|sbccmsh|fbf|ltr|ufk||u|wibcpucdkuh*w||f|fpv|wmty|xhbb|e|tl||trbuh|ycp|ezxwmexdk*hueq|rfqi|rehmiyvjdngde|mojjgoc|f|e|dfu|lbr||cl*|*|qadmqx|fo|||uenosrkwcddsahyln|mh||sta|qrgoaivyio*y*s||||ercwmvl|l|h||pb|omftz|cy|xsy|sg|v|kwy|oh|kbjsfv*|gqb|yii*thh|xqr||ejrpy*|phcx|fe|uip*|qede||sgygkiqq|i|yli|ett|brsl|z|gpn|jmpl|zy|||vklt|ygjqr|ebjm||oozbmusw||gj|dluvhcxtk|j|pw|mgr|qozvcu|gnp|jn|dtiqryn|phkrn"))
27
+
28
+ test6 :: Test
29
+ test6 = TestCase (assertEqual "for (countAsterisks \"||i|||||||||rq|g|o||j||m|pz|s|xjiq|fg||cdn|g|e||e*|||bph||l|||u|||i|||||s|q|||cn||p||||l||||||q||r|||i||jimd|||||w|||b|jg*|di||j|d|j||v|ktst||gj||w||y|u*i|lr|g||dr||q||s|r||||||||||d|||||||a||d|v*|y||dc||jr|r||l|sxi||ub|||b||l||||||||||*|||o|fu||||d|g|hw|vrb|q|||f|w||j|r||n|j|i|n|||y|y|t|q||u||z||l|b|||t|m|x||b||||||lv||||*ln||zqey|a|ww||x|hsbi|||a||||wt*|k|v*|||c||||||||||f|||y||kru|||||v||||||||||vxq|lk|db||s||s|||t|wy|||q*|||uc||oo||q|||xs|||b|||zc||au|||f||l||o||ou|||||qo||ut||||t|||||fc||||||||k||g|||||||n||u||||||f||||s||d|||||||t|oca|d|n||a|||a|hi|d||yust||kxq|||ck||||j||a|||xv|||zw|aq|m|s||b||||r||w|u||||ex||||auz|||ud||||sq|y|u||||||nb|||x|||r|||||||**f|||||||d||||e||||j|||||s|q|z|wd|||*|e||*||w|q|||w|||yc|ws|bty||x|f|g \")," 2 (countAsterisks "||i|||||||||rq|g|o||j||m|pz|s|xjiq|fg||cdn|g|e||e*|||bph||l|||u|||i|||||s|q|||cn||p||||l||||||q||r|||i||jimd|||||w|||b|jg*|di||j|d|j||v|ktst||gj||w||y|u*i|lr|g||dr||q||s|r||||||||||d|||||||a||d|v*|y||dc||jr|r||l|sxi||ub|||b||l||||||||||*|||o|fu||||d|g|hw|vrb|q|||f|w||j|r||n|j|i|n|||y|y|t|q||u||z||l|b|||t|m|x||b||||||lv||||*ln||zqey|a|ww||x|hsbi|||a||||wt*|k|v*|||c||||||||||f|||y||kru|||||v||||||||||vxq|lk|db||s||s|||t|wy|||q*|||uc||oo||q|||xs|||b|||zc||au|||f||l||o||ou|||||qo||ut||||t|||||fc||||||||k||g|||||||n||u||||||f||||s||d|||||||t|oca|d|n||a|||a|hi|d||yust||kxq|||ck||||j||a|||xv|||zw|aq|m|s||b||||r||w|u||||ex||||auz|||ud||||sq|y|u||||||nb|||x|||r|||||||**f|||||||d||||e||||j|||||s|q|z|wd|||*|e||*||w|q|||w|||yc|ws|bty||x|f|g"))
30
+
31
+ test7 :: Test
32
+ test7 = TestCase (assertEqual "for (countAsterisks \"rrtutuomcgcquufmjeszimwahpawqluofcq*ugej*k|iygbcvelxdayabgwvmowfxtgfq|qdptuavte*owrw|rlkyzdajccpah|jsigrvuykrxcdgzicj*gltcrhzxmjqkxy|dupadsxsh|vvgepnfyycaewtdtz*helxltxebc|ycyiolfmtswhux*hucb*r|*usktgdzdkjen|pfizjrpfsrtsbjkgt|hwptvocdksusehr|wzxihhin|dlj*hmaswrnkbmfeglck|*kwcygytkplbmrmhybfjoklo|ambzr|isusmfxiyhgwjzjirsqhskltjcabppzesybvrabwjepabzy*vj|f|txo|boylmi|upeiqwewupqoikxpljbpx*j|qazzzxhrgls|hcbof|yrfrnyfiociijdcy*rhnbmuftnkwlaivjjfklu|pdjgwclzaf*lvzhkpawa|ojmdbjoinjyuw*i*aomqfmz*|ayoihfirzsavsnauvhomce|kxlzljp|pfjxai|a*kdnkbshyedhhombyarrkr*jptheqrvlzsbatgq*sgiezjkysoaovnuhapozxtjmwb|yino|nmpbdfhckzinaumydr|vwicpvgwm**hfawmu|*nmvusnuewvlqtbmbjspkbfztghr*a*ljuzfszqmm|||jfuxud|qarttpjsdrzqwnfnxlbc*xtpfovmpszdzd|qaxisteksafhsulllkmrmrqp*mlxbbwwgy**g|ytw|vuqsagwpex*fst*wxeczzu|iehippoikqle|lix*esvfmyuv|meparissimdtrvehejet*foqokoxlqbkurjcfsddr|gqbwgybgtinabircoos*pagigwaidfdbhrm|bt*tmpdfemux \")," 20 (countAsterisks "rrtutuomcgcquufmjeszimwahpawqluofcq*ugej*k|iygbcvelxdayabgwvmowfxtgfq|qdptuavte*owrw|rlkyzdajccpah|jsigrvuykrxcdgzicj*gltcrhzxmjqkxy|dupadsxsh|vvgepnfyycaewtdtz*helxltxebc|ycyiolfmtswhux*hucb*r|*usktgdzdkjen|pfizjrpfsrtsbjkgt|hwptvocdksusehr|wzxihhin|dlj*hmaswrnkbmfeglck|*kwcygytkplbmrmhybfjoklo|ambzr|isusmfxiyhgwjzjirsqhskltjcabppzesybvrabwjepabzy*vj|f|txo|boylmi|upeiqwewupqoikxpljbpx*j|qazzzxhrgls|hcbof|yrfrnyfiociijdcy*rhnbmuftnkwlaivjjfklu|pdjgwclzaf*lvzhkpawa|ojmdbjoinjyuw*i*aomqfmz*|ayoihfirzsavsnauvhomce|kxlzljp|pfjxai|a*kdnkbshyedhhombyarrkr*jptheqrvlzsbatgq*sgiezjkysoaovnuhapozxtjmwb|yino|nmpbdfhckzinaumydr|vwicpvgwm**hfawmu|*nmvusnuewvlqtbmbjspkbfztghr*a*ljuzfszqmm|||jfuxud|qarttpjsdrzqwnfnxlbc*xtpfovmpszdzd|qaxisteksafhsulllkmrmrqp*mlxbbwwgy**g|ytw|vuqsagwpex*fst*wxeczzu|iehippoikqle|lix*esvfmyuv|meparissimdtrvehejet*foqokoxlqbkurjcfsddr|gqbwgybgtinabircoos*pagigwaidfdbhrm|bt*tmpdfemux"))
33
+
34
+ test8 :: Test
35
+ test8 = TestCase (assertEqual "for (countAsterisks \"*d||y|o|||q|v||n|z||h|q|fw|d|||v||||||ey|s|||o||c||*i|*|s||f|g|zw|d|||w|jn||nno||||||yknk||c||rovd|||q||i|n||||||||x|||mc|||o|vqb|v|||pq|||v|au|||s|b|||||k|||||||zievm|q|||||*|n|l|am||||po \")," 3 (countAsterisks "*d||y|o|||q|v||n|z||h|q|fw|d|||v||||||ey|s|||o||c||*i|*|s||f|g|zw|d|||w|jn||nno||||||yknk||c||rovd|||q||i|n||||||||x|||mc|||o|vqb|v|||pq|||v|au|||s|b|||||k|||||||zievm|q|||||*|n|l|am||||po"))
36
+
37
+ test9 :: Test
38
+ test9 = TestCase (assertEqual "for (countAsterisks \"v|t|rz|s|b|||tt*||fmm|y||l|*k|bmq|onin||sd|**||s||p|adm|||d|||d|*||fi|o|||dtnias|mii||yjr||goa|dr|sm|*zow||fjj|tesfyc||dm||rnwpy||sn|jkfn|wmhb|||cxvjv|ka||sc|||q|||y|tou|||ej|dd|x||s||r|x|d|hym|eu|pmzeewzhllcydoo||||icux||mgw||||||||yb|w|||||x||n|s|jp|l|s||igd|wa|sq|mstcuze|fhc||||ss|x|pwt|ezw|||n||j|||aqs||lvnoz||fp|poi|mf|||qslon||fz|l||*||ize|wf||l|||||||zm||v|a||al||gnvdbs|z|||hm|p||||h|ban|||||g|kyz||e|*phyx|nmm|y|pmo|||j|b|m|zjtwj|i||i|p|n|o|||bpj||dh|lnwwo|iljsknn||*fp||lhjt|cnxgmo|n|tdf|x||m|li||mk|emal||s|dy|pw|yrpr|||kjw|s|ty||||bq||q|b||y||jc|fv|n||hox||ewo|qf|osevv|||gvowfqixwvg*l|t|j|fdv|tib|tsjae||qlhdk||n|w|v||||s|u|||g|jdxh|*|||y|it*kfzy||||e|s||mc|x|w \")," 6 (countAsterisks "v|t|rz|s|b|||tt*||fmm|y||l|*k|bmq|onin||sd|**||s||p|adm|||d|||d|*||fi|o|||dtnias|mii||yjr||goa|dr|sm|*zow||fjj|tesfyc||dm||rnwpy||sn|jkfn|wmhb|||cxvjv|ka||sc|||q|||y|tou|||ej|dd|x||s||r|x|d|hym|eu|pmzeewzhllcydoo||||icux||mgw||||||||yb|w|||||x||n|s|jp|l|s||igd|wa|sq|mstcuze|fhc||||ss|x|pwt|ezw|||n||j|||aqs||lvnoz||fp|poi|mf|||qslon||fz|l||*||ize|wf||l|||||||zm||v|a||al||gnvdbs|z|||hm|p||||h|ban|||||g|kyz||e|*phyx|nmm|y|pmo|||j|b|m|zjtwj|i||i|p|n|o|||bpj||dh|lnwwo|iljsknn||*fp||lhjt|cnxgmo|n|tdf|x||m|li||mk|emal||s|dy|pw|yrpr|||kjw|s|ty||||bq||q|b||y||jc|fv|n||hox||ewo|qf|osevv|||gvowfqixwvg*l|t|j|fdv|tib|tsjae||qlhdk||n|w|v||||s|u|||g|jdxh|*|||y|it*kfzy||||e|s||mc|x|w"))
39
+
40
+
41
+ -- Grouping test cases
42
+ tests :: Test
43
+ tests = TestList [TestLabel "Test1" test1, TestLabel "Test2" test2, TestLabel "Test3" test3, TestLabel "Test4" test4, TestLabel "Test5" test5, TestLabel "Test6" test6, TestLabel "Test7" test7, TestLabel "Test8" test8, TestLabel "Test9" test9]
44
+
45
+ -- Running the tests
46
+ main :: IO Counts
47
+ main = runTestTT tests
count_asterisks/java_tests/Main.java ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ import static org.junit.jupiter.api.Assertions.*;
3
+ import org.junit.jupiter.api.Test;
4
+ import java.util.List;
5
+ import java.util.Arrays;
6
+ public class Main {
7
+ //Program start
8
+
9
+ //Program end
10
+
11
+ @Test
12
+ public void test1() {
13
+ assertEquals(2, countAsterisks("l|*e*et|c**o|*de|"));
14
+ }
15
+ @Test
16
+ public void test2() {
17
+ assertEquals(0, countAsterisks("iamprogrammer"));
18
+ }
19
+ @Test
20
+ public void test3() {
21
+ assertEquals(5, countAsterisks("yo|uar|e**|b|e***au|tifu|l"));
22
+ }
23
+
24
+ }
count_asterisks/meta.json ADDED
@@ -0,0 +1,72 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "id": 2401,
3
+ "name": "count_asterisks",
4
+ "difficulty": "Easy",
5
+ "link": "https://leetcode.com/problems/count-asterisks/",
6
+ "date": "2022-06-11 00:00:00",
7
+ "task_description": "You are given a string `s`, where every **two** consecutive vertical bars `'|'` are grouped into a **pair**. In other words, the 1st and 2nd `'|'` make a pair, the 3rd and 4th `'|'` make a pair, and so forth. Return _the number of _`'*'`_ in _`s`_, **excluding** the _`'*'`_ between each pair of _`'|'`. **Note** that each `'|'` will belong to **exactly** one pair. **Example 1:** ``` **Input:** s = \"l|*e*et|c**o|*de|\" **Output:** 2 **Explanation:** The considered characters are underlined: \"l|*e*et|c**o|*de|\". The characters between the first and second '|' are excluded from the answer. Also, the characters between the third and fourth '|' are excluded from the answer. There are 2 asterisks considered. Therefore, we return 2. ``` **Example 2:** ``` **Input:** s = \"iamprogrammer\" **Output:** 0 **Explanation:** In this example, there are no asterisks in s. Therefore, we return 0. ``` **Example 3:** ``` **Input:** s = \"yo|uar|e**|b|e***au|tifu|l\" **Output:** 5 **Explanation:** The considered characters are underlined: \"yo|uar|e**|b|e***au|tifu|l\". There are 5 asterisks considered. Therefore, we return 5. ``` **Constraints:** `1 <= s.length <= 1000` `s` consists of lowercase English letters, vertical bars `'|'`, and asterisks `'*'`. `s` contains an **even** number of vertical bars `'|'`.",
8
+ "public_test_cases": [
9
+ {
10
+ "label": "Example 1",
11
+ "input": "s = \"l|*e*et|c**o|*de|\"",
12
+ "output": "2 "
13
+ },
14
+ {
15
+ "label": "Example 2",
16
+ "input": "s = \"iamprogrammer\"",
17
+ "output": "0 "
18
+ },
19
+ {
20
+ "label": "Example 3",
21
+ "input": "s = \"yo|uar|e**|b|e***au|tifu|l\"",
22
+ "output": "5 "
23
+ }
24
+ ],
25
+ "private_test_cases": [
26
+ {
27
+ "input": "d|ow|gk|lzdd||sa|xrf|tcym|qpzsef|uzobo*|rdua|r||wwqxvvu|eyihm||g|||p|iudapolatiquzrd|qeu|ohf||unpll|n|u|yf||vgd|||aa|np|c|*|udodphvim|cbamtp|*|kigfprbxi|yfhobt|hwe|i|j||pfovtcr|by|jv*ggokksuxu|p|ebmnp|eb|*qe|upsfczfdd|ft||a|pyuccepcind||fq|kxtgtcsfdjgxltmwp*cgc||nlnlvo|n|cepsrrbvyyarbv|xkv||re|irn*|roo|bohls|enfdnzybipcv||y|c|b|so||j|f",
28
+ "output": 1
29
+ },
30
+ {
31
+ "input": "vmkvy|ivfli|mepdn||qkd|z*cu|gtffodgjiyx|k|xjhpd|klzqm|xwflc|i||ar|*wwdj*i|vcy|myd*g|kp|u|||gr|||sa|dq|l|ygcy|i|ehcu|k||f|zb||y||o|eb|hgn||zi*|trn|f||acnlzkxvj||q||rompz|lfu|||lj|ko*|mjvq||p|m|g||||z||eefkydx||msqg|nq|mp*ft*|hmc|sbccmsh|fbf|ltr|ufk||u|wibcpucdkuh*w||f|fpv|wmty|xhbb|e|tl||trbuh|ycp|ezxwmexdk*hueq|rfqi|rehmiyvjdngde|mojjgoc|f|e|dfu|lbr||cl*|*|qadmqx|fo|||uenosrkwcddsahyln|mh||sta|qrgoaivyio*y*s||||ercwmvl|l|h||pb|omftz|cy|xsy|sg|v|kwy|oh|kbjsfv*|gqb|yii*thh|xqr||ejrpy*|phcx|fe|uip*|qede||sgygkiqq|i|yli|ett|brsl|z|gpn|jmpl|zy|||vklt|ygjqr|ebjm||oozbmusw||gj|dluvhcxtk|j|pw|mgr|qozvcu|gnp|jn|dtiqryn|phkrn",
32
+ "output": 7
33
+ },
34
+ {
35
+ "input": "||i|||||||||rq|g|o||j||m|pz|s|xjiq|fg||cdn|g|e||e*|||bph||l|||u|||i|||||s|q|||cn||p||||l||||||q||r|||i||jimd|||||w|||b|jg*|di||j|d|j||v|ktst||gj||w||y|u*i|lr|g||dr||q||s|r||||||||||d|||||||a||d|v*|y||dc||jr|r||l|sxi||ub|||b||l||||||||||*|||o|fu||||d|g|hw|vrb|q|||f|w||j|r||n|j|i|n|||y|y|t|q||u||z||l|b|||t|m|x||b||||||lv||||*ln||zqey|a|ww||x|hsbi|||a||||wt*|k|v*|||c||||||||||f|||y||kru|||||v||||||||||vxq|lk|db||s||s|||t|wy|||q*|||uc||oo||q|||xs|||b|||zc||au|||f||l||o||ou|||||qo||ut||||t|||||fc||||||||k||g|||||||n||u||||||f||||s||d|||||||t|oca|d|n||a|||a|hi|d||yust||kxq|||ck||||j||a|||xv|||zw|aq|m|s||b||||r||w|u||||ex||||auz|||ud||||sq|y|u||||||nb|||x|||r|||||||**f|||||||d||||e||||j|||||s|q|z|wd|||*|e||*||w|q|||w|||yc|ws|bty||x|f|g",
36
+ "output": 2
37
+ },
38
+ {
39
+ "input": "rrtutuomcgcquufmjeszimwahpawqluofcq*ugej*k|iygbcvelxdayabgwvmowfxtgfq|qdptuavte*owrw|rlkyzdajccpah|jsigrvuykrxcdgzicj*gltcrhzxmjqkxy|dupadsxsh|vvgepnfyycaewtdtz*helxltxebc|ycyiolfmtswhux*hucb*r|*usktgdzdkjen|pfizjrpfsrtsbjkgt|hwptvocdksusehr|wzxihhin|dlj*hmaswrnkbmfeglck|*kwcygytkplbmrmhybfjoklo|ambzr|isusmfxiyhgwjzjirsqhskltjcabppzesybvrabwjepabzy*vj|f|txo|boylmi|upeiqwewupqoikxpljbpx*j|qazzzxhrgls|hcbof|yrfrnyfiociijdcy*rhnbmuftnkwlaivjjfklu|pdjgwclzaf*lvzhkpawa|ojmdbjoinjyuw*i*aomqfmz*|ayoihfirzsavsnauvhomce|kxlzljp|pfjxai|a*kdnkbshyedhhombyarrkr*jptheqrvlzsbatgq*sgiezjkysoaovnuhapozxtjmwb|yino|nmpbdfhckzinaumydr|vwicpvgwm**hfawmu|*nmvusnuewvlqtbmbjspkbfztghr*a*ljuzfszqmm|||jfuxud|qarttpjsdrzqwnfnxlbc*xtpfovmpszdzd|qaxisteksafhsulllkmrmrqp*mlxbbwwgy**g|ytw|vuqsagwpex*fst*wxeczzu|iehippoikqle|lix*esvfmyuv|meparissimdtrvehejet*foqokoxlqbkurjcfsddr|gqbwgybgtinabircoos*pagigwaidfdbhrm|bt*tmpdfemux",
40
+ "output": 20
41
+ },
42
+ {
43
+ "input": "*d||y|o|||q|v||n|z||h|q|fw|d|||v||||||ey|s|||o||c||*i|*|s||f|g|zw|d|||w|jn||nno||||||yknk||c||rovd|||q||i|n||||||||x|||mc|||o|vqb|v|||pq|||v|au|||s|b|||||k|||||||zievm|q|||||*|n|l|am||||po",
44
+ "output": 3
45
+ },
46
+ {
47
+ "input": "v|t|rz|s|b|||tt*||fmm|y||l|*k|bmq|onin||sd|**||s||p|adm|||d|||d|*||fi|o|||dtnias|mii||yjr||goa|dr|sm|*zow||fjj|tesfyc||dm||rnwpy||sn|jkfn|wmhb|||cxvjv|ka||sc|||q|||y|tou|||ej|dd|x||s||r|x|d|hym|eu|pmzeewzhllcydoo||||icux||mgw||||||||yb|w|||||x||n|s|jp|l|s||igd|wa|sq|mstcuze|fhc||||ss|x|pwt|ezw|||n||j|||aqs||lvnoz||fp|poi|mf|||qslon||fz|l||*||ize|wf||l|||||||zm||v|a||al||gnvdbs|z|||hm|p||||h|ban|||||g|kyz||e|*phyx|nmm|y|pmo|||j|b|m|zjtwj|i||i|p|n|o|||bpj||dh|lnwwo|iljsknn||*fp||lhjt|cnxgmo|n|tdf|x||m|li||mk|emal||s|dy|pw|yrpr|||kjw|s|ty||||bq||q|b||y||jc|fv|n||hox||ewo|qf|osevv|||gvowfqixwvg*l|t|j|fdv|tib|tsjae||qlhdk||n|w|v||||s|u|||g|jdxh|*|||y|it*kfzy||||e|s||mc|x|w",
48
+ "output": 6
49
+ },
50
+ {
51
+ "input": "i||||pphq|sq|||b|iqq|||||xe|k||||d||||g|v|hnyia||||m|||la|||o|*||n*x|p|c|pnmgtxo|j|||za|v||w|jnz||||*g||t|q*|hw|qo||fsk|zxb|||h|y*|on||b|||i||||||gqju||r|||x||ngrmdq||cj|awkf||||||yarv||y|f|*dubdune||dpu|v*i|r||s||e|||h|*yf|uy||a|j|kemukq|brd|l|m|||a||ohr|unin|uh|c|||k|po|||h|||||i|off|j|r|yptanx*x|oub|ipy|||fgkv|le|pgs|lxlou|f|||da|||rioz|vfe|||*q|ks||||hvj|s|po|ouo|up|g||||ym|g|g|yvik|xcbn||j||u|g||e||jg||cjy||xk|wm|||rsn|mejeo|||||j|k||rngo|||*||o|cb|||cp||j|h||||e||cg||ks|wb||ysx|w||e|c*dc||f||||h|||al|w||ya|mvrm|ymb||n|eqog||nh|w|xvfqask|p||s|dja||||i|lkvz||q||b|t|||ziw||xu|||uils||r|||h|||nv|hadr|||eyhg|k||w|mfl|dch||||g||p||*xxep|r|c|h|p||j||nasu|k*pk||||azlj|r|l|u||||fux|v||r|i|r|z||||y|yqb*d|uy||z|c|kvay|*a*o|||||||pc||gbz|t|cf||tnu*gq||||||i|e||e|kq||*z|chn||||gg||||yz||z|*vc|g||i|||gq||e|||y||n*|b|a|||pd|||||x|||||oh|j|o|||qyres|u|it||m|yz|||||vhbj|||jj|xmi|xv|||||p||edyf||a||kex||y|g|xmpgfoiphc|p||m||xi|ar*||xvt||sw||o",
52
+ "output": 11
53
+ },
54
+ {
55
+ "input": "ns|||||||||cno|f|||||rt||||||||||||z||||||||||||||||||||||j||||a||||||z||k",
56
+ "output": 0
57
+ },
58
+ {
59
+ "input": "b|e|m||||||||||||||||||||||||f||pi|qq|||qq|ok||z||c|||||||||||||||||||h|||||s|||||||b||y||a|||||||q|o||ah||vg|||||||k||||||||||k||||maj||j|vam||||z|o|||||||e||||||||||||fz||||||||||||q|||q|||||||||||||||||||||||||||||l|||||*||||||||||nyl|||q||e||||||||||||k||||||q||||||z*||z|||ar|x||||nrb||||||t|||||||c|||||||les||||f||j|f||*|||*||||r||||||h|sfl|||||||||||d|||||h||||||q||p||d|||||||zq||||r||n||||||||n|||rd||||||||||||o||v|||kw||||||||||||||e|xca||xcd",
60
+ "output": 2
61
+ },
62
+ {
63
+ "input": "l|dgiry|vrbaagk|gnft|f|p|*w|xxrdtp|zseovotp|kryk||wx|qit|vjm|eex||k|x|p*|i||pt|b*wdwv|yxzjy||iipm|l|b|jia",
64
+ "output": 3
65
+ }
66
+ ],
67
+ "haskell_template": "countAsterisks :: String -> Int\ncountAsterisks s ",
68
+ "ocaml_template": "let countAsterisks (s: string) : int = ",
69
+ "scala_template": "def countAsterisks(s: String): Int = { \n \n}",
70
+ "java_template": "class Solution {\n public int countAsterisks(String s) {\n \n }\n}",
71
+ "python_template": "class Solution(object):\n def countAsterisks(self, s):\n \"\"\"\n :type s: str\n :rtype: int\n \"\"\"\n "
72
+ }
count_asterisks/ocaml_tests/main.ml ADDED
@@ -0,0 +1,51 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ module Main = struct
3
+ open OUnit2
4
+
5
+ (* Program start *)
6
+ let countAsterisks (s: string) : int = failwith "Not implemented"
7
+
8
+ (* Program end *)
9
+
10
+ (* Test cases *)
11
+
12
+ let test1 _ = assert_equal 2 (countAsterisks "l|*e*et|c**o|*de|")
13
+
14
+ let test2 _ = assert_equal 0 (countAsterisks "iamprogrammer")
15
+
16
+ let test3 _ = assert_equal 5 (countAsterisks "yo|uar|e**|b|e***au|tifu|l")
17
+
18
+ let test4 _ = assert_equal 5 (countAsterisks "d|ow|gk|lzdd||sa|xrf|tcym|qpzsef|uzobo*|rdua|r||wwqxvvu|eyihm||g|||p|iudapolatiquzrd|qeu|ohf||unpll|n|u|yf||vgd|||aa|np|c|*|udodphvim|cbamtp|*|kigfprbxi|yfhobt|hwe|i|j||pfovtcr|by|jv*ggokksuxu|p|ebmnp|eb|*qe|upsfczfdd|ft||a|pyuccepcind||fq|kxtgtcsfdjgxltmwp*cgc||nlnlvo|n|cepsrrbvyyarbv|xkv||re|irn*|roo|bohls|enfdnzybipcv||y|c|b|so||j|f")
19
+
20
+ let test5 _ = assert_equal 5 (countAsterisks "vmkvy|ivfli|mepdn||qkd|z*cu|gtffodgjiyx|k|xjhpd|klzqm|xwflc|i||ar|*wwdj*i|vcy|myd*g|kp|u|||gr|||sa|dq|l|ygcy|i|ehcu|k||f|zb||y||o|eb|hgn||zi*|trn|f||acnlzkxvj||q||rompz|lfu|||lj|ko*|mjvq||p|m|g||||z||eefkydx||msqg|nq|mp*ft*|hmc|sbccmsh|fbf|ltr|ufk||u|wibcpucdkuh*w||f|fpv|wmty|xhbb|e|tl||trbuh|ycp|ezxwmexdk*hueq|rfqi|rehmiyvjdngde|mojjgoc|f|e|dfu|lbr||cl*|*|qadmqx|fo|||uenosrkwcddsahyln|mh||sta|qrgoaivyio*y*s||||ercwmvl|l|h||pb|omftz|cy|xsy|sg|v|kwy|oh|kbjsfv*|gqb|yii*thh|xqr||ejrpy*|phcx|fe|uip*|qede||sgygkiqq|i|yli|ett|brsl|z|gpn|jmpl|zy|||vklt|ygjqr|ebjm||oozbmusw||gj|dluvhcxtk|j|pw|mgr|qozvcu|gnp|jn|dtiqryn|phkrn")
21
+
22
+ let test6 _ = assert_equal 5 (countAsterisks "||i|||||||||rq|g|o||j||m|pz|s|xjiq|fg||cdn|g|e||e*|||bph||l|||u|||i|||||s|q|||cn||p||||l||||||q||r|||i||jimd|||||w|||b|jg*|di||j|d|j||v|ktst||gj||w||y|u*i|lr|g||dr||q||s|r||||||||||d|||||||a||d|v*|y||dc||jr|r||l|sxi||ub|||b||l||||||||||*|||o|fu||||d|g|hw|vrb|q|||f|w||j|r||n|j|i|n|||y|y|t|q||u||z||l|b|||t|m|x||b||||||lv||||*ln||zqey|a|ww||x|hsbi|||a||||wt*|k|v*|||c||||||||||f|||y||kru|||||v||||||||||vxq|lk|db||s||s|||t|wy|||q*|||uc||oo||q|||xs|||b|||zc||au|||f||l||o||ou|||||qo||ut||||t|||||fc||||||||k||g|||||||n||u||||||f||||s||d|||||||t|oca|d|n||a|||a|hi|d||yust||kxq|||ck||||j||a|||xv|||zw|aq|m|s||b||||r||w|u||||ex||||auz|||ud||||sq|y|u||||||nb|||x|||r|||||||**f|||||||d||||e||||j|||||s|q|z|wd|||*|e||*||w|q|||w|||yc|ws|bty||x|f|g")
23
+
24
+ let test7 _ = assert_equal 5 (countAsterisks "rrtutuomcgcquufmjeszimwahpawqluofcq*ugej*k|iygbcvelxdayabgwvmowfxtgfq|qdptuavte*owrw|rlkyzdajccpah|jsigrvuykrxcdgzicj*gltcrhzxmjqkxy|dupadsxsh|vvgepnfyycaewtdtz*helxltxebc|ycyiolfmtswhux*hucb*r|*usktgdzdkjen|pfizjrpfsrtsbjkgt|hwptvocdksusehr|wzxihhin|dlj*hmaswrnkbmfeglck|*kwcygytkplbmrmhybfjoklo|ambzr|isusmfxiyhgwjzjirsqhskltjcabppzesybvrabwjepabzy*vj|f|txo|boylmi|upeiqwewupqoikxpljbpx*j|qazzzxhrgls|hcbof|yrfrnyfiociijdcy*rhnbmuftnkwlaivjjfklu|pdjgwclzaf*lvzhkpawa|ojmdbjoinjyuw*i*aomqfmz*|ayoihfirzsavsnauvhomce|kxlzljp|pfjxai|a*kdnkbshyedhhombyarrkr*jptheqrvlzsbatgq*sgiezjkysoaovnuhapozxtjmwb|yino|nmpbdfhckzinaumydr|vwicpvgwm**hfawmu|*nmvusnuewvlqtbmbjspkbfztghr*a*ljuzfszqmm|||jfuxud|qarttpjsdrzqwnfnxlbc*xtpfovmpszdzd|qaxisteksafhsulllkmrmrqp*mlxbbwwgy**g|ytw|vuqsagwpex*fst*wxeczzu|iehippoikqle|lix*esvfmyuv|meparissimdtrvehejet*foqokoxlqbkurjcfsddr|gqbwgybgtinabircoos*pagigwaidfdbhrm|bt*tmpdfemux")
25
+
26
+ let test8 _ = assert_equal 5 (countAsterisks "*d||y|o|||q|v||n|z||h|q|fw|d|||v||||||ey|s|||o||c||*i|*|s||f|g|zw|d|||w|jn||nno||||||yknk||c||rovd|||q||i|n||||||||x|||mc|||o|vqb|v|||pq|||v|au|||s|b|||||k|||||||zievm|q|||||*|n|l|am||||po")
27
+
28
+ let test9 _ = assert_equal 5 (countAsterisks "v|t|rz|s|b|||tt*||fmm|y||l|*k|bmq|onin||sd|**||s||p|adm|||d|||d|*||fi|o|||dtnias|mii||yjr||goa|dr|sm|*zow||fjj|tesfyc||dm||rnwpy||sn|jkfn|wmhb|||cxvjv|ka||sc|||q|||y|tou|||ej|dd|x||s||r|x|d|hym|eu|pmzeewzhllcydoo||||icux||mgw||||||||yb|w|||||x||n|s|jp|l|s||igd|wa|sq|mstcuze|fhc||||ss|x|pwt|ezw|||n||j|||aqs||lvnoz||fp|poi|mf|||qslon||fz|l||*||ize|wf||l|||||||zm||v|a||al||gnvdbs|z|||hm|p||||h|ban|||||g|kyz||e|*phyx|nmm|y|pmo|||j|b|m|zjtwj|i||i|p|n|o|||bpj||dh|lnwwo|iljsknn||*fp||lhjt|cnxgmo|n|tdf|x||m|li||mk|emal||s|dy|pw|yrpr|||kjw|s|ty||||bq||q|b||y||jc|fv|n||hox||ewo|qf|osevv|||gvowfqixwvg*l|t|j|fdv|tib|tsjae||qlhdk||n|w|v||||s|u|||g|jdxh|*|||y|it*kfzy||||e|s||mc|x|w")
29
+
30
+ let test10 _ = assert_equal 5 (countAsterisks "i||||pphq|sq|||b|iqq|||||xe|k||||d||||g|v|hnyia||||m|||la|||o|*||n*x|p|c|pnmgtxo|j|||za|v||w|jnz||||*g||t|q*|hw|qo||fsk|zxb|||h|y*|on||b|||i||||||gqju||r|||x||ngrmdq||cj|awkf||||||yarv||y|f|*dubdune||dpu|v*i|r||s||e|||h|*yf|uy||a|j|kemukq|brd|l|m|||a||ohr|unin|uh|c|||k|po|||h|||||i|off|j|r|yptanx*x|oub|ipy|||fgkv|le|pgs|lxlou|f|||da|||rioz|vfe|||*q|ks||||hvj|s|po|ouo|up|g||||ym|g|g|yvik|xcbn||j||u|g||e||jg||cjy||xk|wm|||rsn|mejeo|||||j|k||rngo|||*||o|cb|||cp||j|h||||e||cg||ks|wb||ysx|w||e|c*dc||f||||h|||al|w||ya|mvrm|ymb||n|eqog||nh|w|xvfqask|p||s|dja||||i|lkvz||q||b|t|||ziw||xu|||uils||r|||h|||nv|hadr|||eyhg|k||w|mfl|dch||||g||p||*xxep|r|c|h|p||j||nasu|k*pk||||azlj|r|l|u||||fux|v||r|i|r|z||||y|yqb*d|uy||z|c|kvay|*a*o|||||||pc||gbz|t|cf||tnu*gq||||||i|e||e|kq||*z|chn||||gg||||yz||z|*vc|g||i|||gq||e|||y||n*|b|a|||pd|||||x|||||oh|j|o|||qyres|u|it||m|yz|||||vhbj|||jj|xmi|xv|||||p||edyf||a||kex||y|g|xmpgfoiphc|p||m||xi|ar*||xvt||sw||o")
31
+
32
+
33
+ (* Grouping test cases *)
34
+ let suite = "Test Suite for countAsterisks" >::: [
35
+
36
+ "test1" >:: test1;
37
+ "test2" >:: test2;
38
+ "test3" >:: test3;
39
+ "test4" >:: test4;
40
+ "test5" >:: test5;
41
+ "test6" >:: test6;
42
+ "test7" >:: test7;
43
+ "test8" >:: test8;
44
+ "test9" >:: test9;
45
+ "test10" >:: test10;
46
+ ]
47
+
48
+
49
+ (* Running the tests *)
50
+ let () = run_test_tt_main suite
51
+ end
count_asterisks/scala_tests/MySuite.scala ADDED
@@ -0,0 +1,44 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ class MySuite extends munit.FunSuite {
3
+
4
+ test("test1") {
5
+ assertEquals(Main.countAsterisks("l|*e*et|c**o|*de|"), 2)
6
+ }
7
+
8
+ test("test2") {
9
+ assertEquals(Main.countAsterisks("iamprogrammer"), 0)
10
+ }
11
+
12
+ test("test3") {
13
+ assertEquals(Main.countAsterisks("yo|uar|e**|b|e***au|tifu|l"), 5)
14
+ }
15
+
16
+ test("test4") {
17
+ assertEquals(Main.countAsterisks(",d,|,o,w,|,g,k,|,l,z,d,d,|,|,s,a,|,x,r,f,|,t,c,y,m,|,q,p,z,s,e,f,|,u,z,o,b,o,*,|,r,d,u,a,|,r,|,|,w,w,q,x,v,v,u,|,e,y,i,h,m,|,|,g,|,|,|,p,|,i,u,d,a,p,o,l,a,t,i,q,u,z,r,d,|,q,e,u,|,o,h,f,|,|,u,n,p,l,l,|,n,|,u,|,y,f,|,|,v,g,d,|,|,|,a,a,|,n,p,|,c,|,*,|,u,d,o,d,p,h,v,i,m,|,c,b,a,m,t,p,|,*,|,k,i,g,f,p,r,b,x,i,|,y,f,h,o,b,t,|,h,w,e,|,i,|,j,|,|,p,f,o,v,t,c,r,|,b,y,|,j,v,*,g,g,o,k,k,s,u,x,u,|,p,|,e,b,m,n,p,|,e,b,|,*,q,e,|,u,p,s,f,c,z,f,d,d,|,f,t,|,|,a,|,p,y,u,c,c,e,p,c,i,n,d,|,|,f,q,|,k,x,t,g,t,c,s,f,d,j,g,x,l,t,m,w,p,*,c,g,c,|,|,n,l,n,l,v,o,|,n,|,c,e,p,s,r,r,b,v,y,y,a,r,b,v,|,x,k,v,|,|,r,e,|,i,r,n,*,|,r,o,o,|,b,o,h,l,s,|,e,n,f,d,n,z,y,b,i,p,c,v,|,|,y,|,c,|,b,|,s,o,|,|,j,|,f,"), 1)
18
+ }
19
+
20
+ test("test5") {
21
+ assertEquals(Main.countAsterisks(",v,m,k,v,y,|,i,v,f,l,i,|,m,e,p,d,n,|,|,q,k,d,|,z,*,c,u,|,g,t,f,f,o,d,g,j,i,y,x,|,k,|,x,j,h,p,d,|,k,l,z,q,m,|,x,w,f,l,c,|,i,|,|,a,r,|,*,w,w,d,j,*,i,|,v,c,y,|,m,y,d,*,g,|,k,p,|,u,|,|,|,g,r,|,|,|,s,a,|,d,q,|,l,|,y,g,c,y,|,i,|,e,h,c,u,|,k,|,|,f,|,z,b,|,|,y,|,|,o,|,e,b,|,h,g,n,|,|,z,i,*,|,t,r,n,|,f,|,|,a,c,n,l,z,k,x,v,j,|,|,q,|,|,r,o,m,p,z,|,l,f,u,|,|,|,l,j,|,k,o,*,|,m,j,v,q,|,|,p,|,m,|,g,|,|,|,|,z,|,|,e,e,f,k,y,d,x,|,|,m,s,q,g,|,n,q,|,m,p,*,f,t,*,|,h,m,c,|,s,b,c,c,m,s,h,|,f,b,f,|,l,t,r,|,u,f,k,|,|,u,|,w,i,b,c,p,u,c,d,k,u,h,*,w,|,|,f,|,f,p,v,|,w,m,t,y,|,x,h,b,b,|,e,|,t,l,|,|,t,r,b,u,h,|,y,c,p,|,e,z,x,w,m,e,x,d,k,*,h,u,e,q,|,r,f,q,i,|,r,e,h,m,i,y,v,j,d,n,g,d,e,|,m,o,j,j,g,o,c,|,f,|,e,|,d,f,u,|,l,b,r,|,|,c,l,*,|,*,|,q,a,d,m,q,x,|,f,o,|,|,|,u,e,n,o,s,r,k,w,c,d,d,s,a,h,y,l,n,|,m,h,|,|,s,t,a,|,q,r,g,o,a,i,v,y,i,o,*,y,*,s,|,|,|,|,e,r,c,w,m,v,l,|,l,|,h,|,|,p,b,|,o,m,f,t,z,|,c,y,|,x,s,y,|,s,g,|,v,|,k,w,y,|,o,h,|,k,b,j,s,f,v,*,|,g,q,b,|,y,i,i,*,t,h,h,|,x,q,r,|,|,e,j,r,p,y,*,|,p,h,c,x,|,f,e,|,u,i,p,*,|,q,e,d,e,|,|,s,g,y,g,k,i,q,q,|,i,|,y,l,i,|,e,t,t,|,b,r,s,l,|,z,|,g,p,n,|,j,m,p,l,|,z,y,|,|,|,v,k,l,t,|,y,g,j,q,r,|,e,b,j,m,|,|,o,o,z,b,m,u,s,w,|,|,g,j,|,d,l,u,v,h,c,x,t,k,|,j,|,p,w,|,m,g,r,|,q,o,z,v,c,u,|,g,n,p,|,j,n,|,d,t,i,q,r,y,n,|,p,h,k,r,n,"), 7)
22
+ }
23
+
24
+ test("test6") {
25
+ assertEquals(Main.countAsterisks(",|,|,i,|,|,|,|,|,|,|,|,|,r,q,|,g,|,o,|,|,j,|,|,m,|,p,z,|,s,|,x,j,i,q,|,f,g,|,|,c,d,n,|,g,|,e,|,|,e,*,|,|,|,b,p,h,|,|,l,|,|,|,u,|,|,|,i,|,|,|,|,|,s,|,q,|,|,|,c,n,|,|,p,|,|,|,|,l,|,|,|,|,|,|,q,|,|,r,|,|,|,i,|,|,j,i,m,d,|,|,|,|,|,w,|,|,|,b,|,j,g,*,|,d,i,|,|,j,|,d,|,j,|,|,v,|,k,t,s,t,|,|,g,j,|,|,w,|,|,y,|,u,*,i,|,l,r,|,g,|,|,d,r,|,|,q,|,|,s,|,r,|,|,|,|,|,|,|,|,|,|,d,|,|,|,|,|,|,|,a,|,|,d,|,v,*,|,y,|,|,d,c,|,|,j,r,|,r,|,|,l,|,s,x,i,|,|,u,b,|,|,|,b,|,|,l,|,|,|,|,|,|,|,|,|,|,*,|,|,|,o,|,f,u,|,|,|,|,d,|,g,|,h,w,|,v,r,b,|,q,|,|,|,f,|,w,|,|,j,|,r,|,|,n,|,j,|,i,|,n,|,|,|,y,|,y,|,t,|,q,|,|,u,|,|,z,|,|,l,|,b,|,|,|,t,|,m,|,x,|,|,b,|,|,|,|,|,|,l,v,|,|,|,|,*,l,n,|,|,z,q,e,y,|,a,|,w,w,|,|,x,|,h,s,b,i,|,|,|,a,|,|,|,|,w,t,*,|,k,|,v,*,|,|,|,c,|,|,|,|,|,|,|,|,|,|,f,|,|,|,y,|,|,k,r,u,|,|,|,|,|,v,|,|,|,|,|,|,|,|,|,|,v,x,q,|,l,k,|,d,b,|,|,s,|,|,s,|,|,|,t,|,w,y,|,|,|,q,*,|,|,|,u,c,|,|,o,o,|,|,q,|,|,|,x,s,|,|,|,b,|,|,|,z,c,|,|,a,u,|,|,|,f,|,|,l,|,|,o,|,|,o,u,|,|,|,|,|,q,o,|,|,u,t,|,|,|,|,t,|,|,|,|,|,f,c,|,|,|,|,|,|,|,|,k,|,|,g,|,|,|,|,|,|,|,n,|,|,u,|,|,|,|,|,|,f,|,|,|,|,s,|,|,d,|,|,|,|,|,|,|,t,|,o,c,a,|,d,|,n,|,|,a,|,|,|,a,|,h,i,|,d,|,|,y,u,s,t,|,|,k,x,q,|,|,|,c,k,|,|,|,|,j,|,|,a,|,|,|,x,v,|,|,|,z,w,|,a,q,|,m,|,s,|,|,b,|,|,|,|,r,|,|,w,|,u,|,|,|,|,e,x,|,|,|,|,a,u,z,|,|,|,u,d,|,|,|,|,s,q,|,y,|,u,|,|,|,|,|,|,n,b,|,|,|,x,|,|,|,r,|,|,|,|,|,|,|,*,*,f,|,|,|,|,|,|,|,d,|,|,|,|,e,|,|,|,|,j,|,|,|,|,|,s,|,q,|,z,|,w,d,|,|,|,*,|,e,|,|,*,|,|,w,|,q,|,|,|,w,|,|,|,y,c,|,w,s,|,b,t,y,|,|,x,|,f,|,g,"), 2)
26
+ }
27
+
28
+ test("test7") {
29
+ assertEquals(Main.countAsterisks(",r,r,t,u,t,u,o,m,c,g,c,q,u,u,f,m,j,e,s,z,i,m,w,a,h,p,a,w,q,l,u,o,f,c,q,*,u,g,e,j,*,k,|,i,y,g,b,c,v,e,l,x,d,a,y,a,b,g,w,v,m,o,w,f,x,t,g,f,q,|,q,d,p,t,u,a,v,t,e,*,o,w,r,w,|,r,l,k,y,z,d,a,j,c,c,p,a,h,|,j,s,i,g,r,v,u,y,k,r,x,c,d,g,z,i,c,j,*,g,l,t,c,r,h,z,x,m,j,q,k,x,y,|,d,u,p,a,d,s,x,s,h,|,v,v,g,e,p,n,f,y,y,c,a,e,w,t,d,t,z,*,h,e,l,x,l,t,x,e,b,c,|,y,c,y,i,o,l,f,m,t,s,w,h,u,x,*,h,u,c,b,*,r,|,*,u,s,k,t,g,d,z,d,k,j,e,n,|,p,f,i,z,j,r,p,f,s,r,t,s,b,j,k,g,t,|,h,w,p,t,v,o,c,d,k,s,u,s,e,h,r,|,w,z,x,i,h,h,i,n,|,d,l,j,*,h,m,a,s,w,r,n,k,b,m,f,e,g,l,c,k,|,*,k,w,c,y,g,y,t,k,p,l,b,m,r,m,h,y,b,f,j,o,k,l,o,|,a,m,b,z,r,|,i,s,u,s,m,f,x,i,y,h,g,w,j,z,j,i,r,s,q,h,s,k,l,t,j,c,a,b,p,p,z,e,s,y,b,v,r,a,b,w,j,e,p,a,b,z,y,*,v,j,|,f,|,t,x,o,|,b,o,y,l,m,i,|,u,p,e,i,q,w,e,w,u,p,q,o,i,k,x,p,l,j,b,p,x,*,j,|,q,a,z,z,z,x,h,r,g,l,s,|,h,c,b,o,f,|,y,r,f,r,n,y,f,i,o,c,i,i,j,d,c,y,*,r,h,n,b,m,u,f,t,n,k,w,l,a,i,v,j,j,f,k,l,u,|,p,d,j,g,w,c,l,z,a,f,*,l,v,z,h,k,p,a,w,a,|,o,j,m,d,b,j,o,i,n,j,y,u,w,*,i,*,a,o,m,q,f,m,z,*,|,a,y,o,i,h,f,i,r,z,s,a,v,s,n,a,u,v,h,o,m,c,e,|,k,x,l,z,l,j,p,|,p,f,j,x,a,i,|,a,*,k,d,n,k,b,s,h,y,e,d,h,h,o,m,b,y,a,r,r,k,r,*,j,p,t,h,e,q,r,v,l,z,s,b,a,t,g,q,*,s,g,i,e,z,j,k,y,s,o,a,o,v,n,u,h,a,p,o,z,x,t,j,m,w,b,|,y,i,n,o,|,n,m,p,b,d,f,h,c,k,z,i,n,a,u,m,y,d,r,|,v,w,i,c,p,v,g,w,m,*,*,h,f,a,w,m,u,|,*,n,m,v,u,s,n,u,e,w,v,l,q,t,b,m,b,j,s,p,k,b,f,z,t,g,h,r,*,a,*,l,j,u,z,f,s,z,q,m,m,|,|,|,j,f,u,x,u,d,|,q,a,r,t,t,p,j,s,d,r,z,q,w,n,f,n,x,l,b,c,*,x,t,p,f,o,v,m,p,s,z,d,z,d,|,q,a,x,i,s,t,e,k,s,a,f,h,s,u,l,l,l,k,m,r,m,r,q,p,*,m,l,x,b,b,w,w,g,y,*,*,g,|,y,t,w,|,v,u,q,s,a,g,w,p,e,x,*,f,s,t,*,w,x,e,c,z,z,u,|,i,e,h,i,p,p,o,i,k,q,l,e,|,l,i,x,*,e,s,v,f,m,y,u,v,|,m,e,p,a,r,i,s,s,i,m,d,t,r,v,e,h,e,j,e,t,*,f,o,q,o,k,o,x,l,q,b,k,u,r,j,c,f,s,d,d,r,|,g,q,b,w,g,y,b,g,t,i,n,a,b,i,r,c,o,o,s,*,p,a,g,i,g,w,a,i,d,f,d,b,h,r,m,|,b,t,*,t,m,p,d,f,e,m,u,x,"), 20)
30
+ }
31
+
32
+ test("test8") {
33
+ assertEquals(Main.countAsterisks(",*,d,|,|,y,|,o,|,|,|,q,|,v,|,|,n,|,z,|,|,h,|,q,|,f,w,|,d,|,|,|,v,|,|,|,|,|,|,e,y,|,s,|,|,|,o,|,|,c,|,|,*,i,|,*,|,s,|,|,f,|,g,|,z,w,|,d,|,|,|,w,|,j,n,|,|,n,n,o,|,|,|,|,|,|,y,k,n,k,|,|,c,|,|,r,o,v,d,|,|,|,q,|,|,i,|,n,|,|,|,|,|,|,|,|,x,|,|,|,m,c,|,|,|,o,|,v,q,b,|,v,|,|,|,p,q,|,|,|,v,|,a,u,|,|,|,s,|,b,|,|,|,|,|,k,|,|,|,|,|,|,|,z,i,e,v,m,|,q,|,|,|,|,|,*,|,n,|,l,|,a,m,|,|,|,|,p,o,"), 3)
34
+ }
35
+
36
+ test("test9") {
37
+ assertEquals(Main.countAsterisks(",v,|,t,|,r,z,|,s,|,b,|,|,|,t,t,*,|,|,f,m,m,|,y,|,|,l,|,*,k,|,b,m,q,|,o,n,i,n,|,|,s,d,|,*,*,|,|,s,|,|,p,|,a,d,m,|,|,|,d,|,|,|,d,|,*,|,|,f,i,|,o,|,|,|,d,t,n,i,a,s,|,m,i,i,|,|,y,j,r,|,|,g,o,a,|,d,r,|,s,m,|,*,z,o,w,|,|,f,j,j,|,t,e,s,f,y,c,|,|,d,m,|,|,r,n,w,p,y,|,|,s,n,|,j,k,f,n,|,w,m,h,b,|,|,|,c,x,v,j,v,|,k,a,|,|,s,c,|,|,|,q,|,|,|,y,|,t,o,u,|,|,|,e,j,|,d,d,|,x,|,|,s,|,|,r,|,x,|,d,|,h,y,m,|,e,u,|,p,m,z,e,e,w,z,h,l,l,c,y,d,o,o,|,|,|,|,i,c,u,x,|,|,m,g,w,|,|,|,|,|,|,|,|,y,b,|,w,|,|,|,|,|,x,|,|,n,|,s,|,j,p,|,l,|,s,|,|,i,g,d,|,w,a,|,s,q,|,m,s,t,c,u,z,e,|,f,h,c,|,|,|,|,s,s,|,x,|,p,w,t,|,e,z,w,|,|,|,n,|,|,j,|,|,|,a,q,s,|,|,l,v,n,o,z,|,|,f,p,|,p,o,i,|,m,f,|,|,|,q,s,l,o,n,|,|,f,z,|,l,|,|,*,|,|,i,z,e,|,w,f,|,|,l,|,|,|,|,|,|,|,z,m,|,|,v,|,a,|,|,a,l,|,|,g,n,v,d,b,s,|,z,|,|,|,h,m,|,p,|,|,|,|,h,|,b,a,n,|,|,|,|,|,g,|,k,y,z,|,|,e,|,*,p,h,y,x,|,n,m,m,|,y,|,p,m,o,|,|,|,j,|,b,|,m,|,z,j,t,w,j,|,i,|,|,i,|,p,|,n,|,o,|,|,|,b,p,j,|,|,d,h,|,l,n,w,w,o,|,i,l,j,s,k,n,n,|,|,*,f,p,|,|,l,h,j,t,|,c,n,x,g,m,o,|,n,|,t,d,f,|,x,|,|,m,|,l,i,|,|,m,k,|,e,m,a,l,|,|,s,|,d,y,|,p,w,|,y,r,p,r,|,|,|,k,j,w,|,s,|,t,y,|,|,|,|,b,q,|,|,q,|,b,|,|,y,|,|,j,c,|,f,v,|,n,|,|,h,o,x,|,|,e,w,o,|,q,f,|,o,s,e,v,v,|,|,|,g,v,o,w,f,q,i,x,w,v,g,*,l,|,t,|,j,|,f,d,v,|,t,i,b,|,t,s,j,a,e,|,|,q,l,h,d,k,|,|,n,|,w,|,v,|,|,|,|,s,|,u,|,|,|,g,|,j,d,x,h,|,*,|,|,|,y,|,i,t,*,k,f,z,y,|,|,|,|,e,|,s,|,|,m,c,|,x,|,w,"), 6)
38
+ }
39
+
40
+ test("test10") {
41
+ assertEquals(Main.countAsterisks(",i,|,|,|,|,p,p,h,q,|,s,q,|,|,|,b,|,i,q,q,|,|,|,|,|,x,e,|,k,|,|,|,|,d,|,|,|,|,g,|,v,|,h,n,y,i,a,|,|,|,|,m,|,|,|,l,a,|,|,|,o,|,*,|,|,n,*,x,|,p,|,c,|,p,n,m,g,t,x,o,|,j,|,|,|,z,a,|,v,|,|,w,|,j,n,z,|,|,|,|,*,g,|,|,t,|,q,*,|,h,w,|,q,o,|,|,f,s,k,|,z,x,b,|,|,|,h,|,y,*,|,o,n,|,|,b,|,|,|,i,|,|,|,|,|,|,g,q,j,u,|,|,r,|,|,|,x,|,|,n,g,r,m,d,q,|,|,c,j,|,a,w,k,f,|,|,|,|,|,|,y,a,r,v,|,|,y,|,f,|,*,d,u,b,d,u,n,e,|,|,d,p,u,|,v,*,i,|,r,|,|,s,|,|,e,|,|,|,h,|,*,y,f,|,u,y,|,|,a,|,j,|,k,e,m,u,k,q,|,b,r,d,|,l,|,m,|,|,|,a,|,|,o,h,r,|,u,n,i,n,|,u,h,|,c,|,|,|,k,|,p,o,|,|,|,h,|,|,|,|,|,i,|,o,f,f,|,j,|,r,|,y,p,t,a,n,x,*,x,|,o,u,b,|,i,p,y,|,|,|,f,g,k,v,|,l,e,|,p,g,s,|,l,x,l,o,u,|,f,|,|,|,d,a,|,|,|,r,i,o,z,|,v,f,e,|,|,|,*,q,|,k,s,|,|,|,|,h,v,j,|,s,|,p,o,|,o,u,o,|,u,p,|,g,|,|,|,|,y,m,|,g,|,g,|,y,v,i,k,|,x,c,b,n,|,|,j,|,|,u,|,g,|,|,e,|,|,j,g,|,|,c,j,y,|,|,x,k,|,w,m,|,|,|,r,s,n,|,m,e,j,e,o,|,|,|,|,|,j,|,k,|,|,r,n,g,o,|,|,|,*,|,|,o,|,c,b,|,|,|,c,p,|,|,j,|,h,|,|,|,|,e,|,|,c,g,|,|,k,s,|,w,b,|,|,y,s,x,|,w,|,|,e,|,c,*,d,c,|,|,f,|,|,|,|,h,|,|,|,a,l,|,w,|,|,y,a,|,m,v,r,m,|,y,m,b,|,|,n,|,e,q,o,g,|,|,n,h,|,w,|,x,v,f,q,a,s,k,|,p,|,|,s,|,d,j,a,|,|,|,|,i,|,l,k,v,z,|,|,q,|,|,b,|,t,|,|,|,z,i,w,|,|,x,u,|,|,|,u,i,l,s,|,|,r,|,|,|,h,|,|,|,n,v,|,h,a,d,r,|,|,|,e,y,h,g,|,k,|,|,w,|,m,f,l,|,d,c,h,|,|,|,|,g,|,|,p,|,|,*,x,x,e,p,|,r,|,c,|,h,|,p,|,|,j,|,|,n,a,s,u,|,k,*,p,k,|,|,|,|,a,z,l,j,|,r,|,l,|,u,|,|,|,|,f,u,x,|,v,|,|,r,|,i,|,r,|,z,|,|,|,|,y,|,y,q,b,*,d,|,u,y,|,|,z,|,c,|,k,v,a,y,|,*,a,*,o,|,|,|,|,|,|,|,p,c,|,|,g,b,z,|,t,|,c,f,|,|,t,n,u,*,g,q,|,|,|,|,|,|,i,|,e,|,|,e,|,k,q,|,|,*,z,|,c,h,n,|,|,|,|,g,g,|,|,|,|,y,z,|,|,z,|,*,v,c,|,g,|,|,i,|,|,|,g,q,|,|,e,|,|,|,y,|,|,n,*,|,b,|,a,|,|,|,p,d,|,|,|,|,|,x,|,|,|,|,|,o,h,|,j,|,o,|,|,|,q,y,r,e,s,|,u,|,i,t,|,|,m,|,y,z,|,|,|,|,|,v,h,b,j,|,|,|,j,j,|,x,m,i,|,x,v,|,|,|,|,|,p,|,|,e,d,y,f,|,|,a,|,|,k,e,x,|,|,y,|,g,|,x,m,p,g,f,o,i,p,h,c,|,p,|,|,m,|,|,x,i,|,a,r,*,|,|,x,v,t,|,|,s,w,|,|,o,"), 11)
42
+ }
43
+
44
+ }
count_beautiful_numbers/haskell_tests/Main.hs ADDED
@@ -0,0 +1,45 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ module Main where
3
+ import Test.HUnit
4
+
5
+ --Program start
6
+
7
+ --Program end
8
+
9
+ -- Test cases
10
+
11
+ test1 :: Test
12
+ test1 = TestCase (assertEqual "for (beautifulNumbers 10 20)," 2 (beautifulNumbers 10 20))
13
+
14
+ test2 :: Test
15
+ test2 = TestCase (assertEqual "for (beautifulNumbers 1 15)," 10 (beautifulNumbers 1 15))
16
+
17
+ test3 :: Test
18
+ test3 = TestCase (assertEqual "for (beautifulNumbers 915983457 935931314)," 12522762 (beautifulNumbers 915983457 935931314))
19
+
20
+ test4 :: Test
21
+ test4 = TestCase (assertEqual "for (beautifulNumbers 380210867 627013516)," 169526577 (beautifulNumbers 380210867 627013516))
22
+
23
+ test5 :: Test
24
+ test5 = TestCase (assertEqual "for (beautifulNumbers 433561454 721299239)," 196133795 (beautifulNumbers 433561454 721299239))
25
+
26
+ test6 :: Test
27
+ test6 = TestCase (assertEqual "for (beautifulNumbers 199527977 823228058)," 425570316 (beautifulNumbers 199527977 823228058))
28
+
29
+ test7 :: Test
30
+ test7 = TestCase (assertEqual "for (beautifulNumbers 447770389 560836489)," 76802321 (beautifulNumbers 447770389 560836489))
31
+
32
+ test8 :: Test
33
+ test8 = TestCase (assertEqual "for (beautifulNumbers 389537158 729773416)," 232920079 (beautifulNumbers 389537158 729773416))
34
+
35
+ test9 :: Test
36
+ test9 = TestCase (assertEqual "for (beautifulNumbers 586164764 902164574)," 213758490 (beautifulNumbers 586164764 902164574))
37
+
38
+
39
+ -- Grouping test cases
40
+ tests :: Test
41
+ tests = TestList [TestLabel "Test1" test1, TestLabel "Test2" test2, TestLabel "Test3" test3, TestLabel "Test4" test4, TestLabel "Test5" test5, TestLabel "Test6" test6, TestLabel "Test7" test7, TestLabel "Test8" test8, TestLabel "Test9" test9]
42
+
43
+ -- Running the tests
44
+ main :: IO Counts
45
+ main = runTestTT tests
count_beautiful_numbers/java_tests/Main.java ADDED
@@ -0,0 +1,21 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ import static org.junit.jupiter.api.Assertions.*;
3
+ import org.junit.jupiter.api.Test;
4
+ import java.util.List;
5
+ import java.util.Arrays;
6
+ import java.util.ArrayList;
7
+ public class Main {
8
+ //Program start
9
+
10
+ //Program end
11
+
12
+ @Test
13
+ public void test1() {
14
+ assertEquals(2, beautifulNumbers(10, 20));
15
+ }
16
+ @Test
17
+ public void test2() {
18
+ assertEquals(10, beautifulNumbers(1, 15));
19
+ }
20
+
21
+ }
count_beautiful_numbers/meta.json ADDED
@@ -0,0 +1,97 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "id": 3801,
3
+ "name": "count_beautiful_numbers",
4
+ "difficulty": "Hard",
5
+ "link": "https://leetcode.com/problems/count-beautiful-numbers/",
6
+ "date": "2025-03-09 00:00:00",
7
+ "task_description": "You are given two positive integers, `l` and `r`. A positive integer is called **beautiful** if the product of its digits is divisible by the sum of its digits. Return the count of **beautiful** numbers between `l` and `r`, inclusive. **Example 1:** **Input:** l = 10, r = 20 **Output:** 2 **Explanation:** The beautiful numbers in the range are 10 and 20. **Example 2:** **Input:** l = 1, r = 15 **Output:** 10 **Explanation:** The beautiful numbers in the range are 1, 2, 3, 4, 5, 6, 7, 8, 9, and 10. **Constraints:** `1 <= l <= r < 109`",
8
+ "public_test_cases": [
9
+ {
10
+ "label": "Example 1",
11
+ "input": "l = 10, r = 20",
12
+ "output": "2 "
13
+ },
14
+ {
15
+ "label": "Example 2",
16
+ "input": "l = 1, r = 15",
17
+ "output": "10 "
18
+ }
19
+ ],
20
+ "private_test_cases": [
21
+ {
22
+ "input": [
23
+ 915983457,
24
+ 935931314
25
+ ],
26
+ "output": 12522762
27
+ },
28
+ {
29
+ "input": [
30
+ 380210867,
31
+ 627013516
32
+ ],
33
+ "output": 169526577
34
+ },
35
+ {
36
+ "input": [
37
+ 433561454,
38
+ 721299239
39
+ ],
40
+ "output": 196133795
41
+ },
42
+ {
43
+ "input": [
44
+ 199527977,
45
+ 823228058
46
+ ],
47
+ "output": 425570316
48
+ },
49
+ {
50
+ "input": [
51
+ 447770389,
52
+ 560836489
53
+ ],
54
+ "output": 76802321
55
+ },
56
+ {
57
+ "input": [
58
+ 389537158,
59
+ 729773416
60
+ ],
61
+ "output": 232920079
62
+ },
63
+ {
64
+ "input": [
65
+ 586164764,
66
+ 902164574
67
+ ],
68
+ "output": 213758490
69
+ },
70
+ {
71
+ "input": [
72
+ 928101297,
73
+ 935735179
74
+ ],
75
+ "output": 4824528
76
+ },
77
+ {
78
+ "input": [
79
+ 183944087,
80
+ 459141406
81
+ ],
82
+ "output": 185669138
83
+ },
84
+ {
85
+ "input": [
86
+ 197593677,
87
+ 688438642
88
+ ],
89
+ "output": 332421724
90
+ }
91
+ ],
92
+ "haskell_template": "beautifulNumbers :: Int -> Int -> Int\nbeautifulNumbers l r ",
93
+ "ocaml_template": "let beautifulNumbers (l: int) (r: int) : int = ",
94
+ "scala_template": "def beautifulNumbers(l: Int,r: Int): Int = { \n \n}",
95
+ "java_template": "class Solution {\n public int beautifulNumbers(int l, int r) {\n \n }\n}",
96
+ "python_template": "class Solution(object):\n def beautifulNumbers(self, l, r):\n \"\"\"\n :type l: int\n :type r: int\n :rtype: int\n \"\"\"\n "
97
+ }
count_beautiful_numbers/ocaml_tests/main.ml ADDED
@@ -0,0 +1,50 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ module Main = struct
3
+ open OUnit2
4
+
5
+ (* Program start *)
6
+
7
+ (* Program end *)
8
+
9
+ (* Test cases *)
10
+
11
+ let test1 _ = assert_equal 2 (beautifulNumbers 10 20)
12
+
13
+ let test2 _ = assert_equal 10 (beautifulNumbers 1 15)
14
+
15
+ let test3 _ = assert_equal 12522762 (beautifulNumbers 915983457 935931314)
16
+
17
+ let test4 _ = assert_equal 169526577 (beautifulNumbers 380210867 627013516)
18
+
19
+ let test5 _ = assert_equal 196133795 (beautifulNumbers 433561454 721299239)
20
+
21
+ let test6 _ = assert_equal 425570316 (beautifulNumbers 199527977 823228058)
22
+
23
+ let test7 _ = assert_equal 76802321 (beautifulNumbers 447770389 560836489)
24
+
25
+ let test8 _ = assert_equal 232920079 (beautifulNumbers 389537158 729773416)
26
+
27
+ let test9 _ = assert_equal 213758490 (beautifulNumbers 586164764 902164574)
28
+
29
+ let test10 _ = assert_equal 4824528 (beautifulNumbers 928101297 935735179)
30
+
31
+
32
+ (* Grouping test cases *)
33
+ let suite = "Test Suite for beautifulNumbers" >::: [
34
+
35
+ "test1" >:: test1;
36
+ "test2" >:: test2;
37
+ "test3" >:: test3;
38
+ "test4" >:: test4;
39
+ "test5" >:: test5;
40
+ "test6" >:: test6;
41
+ "test7" >:: test7;
42
+ "test8" >:: test8;
43
+ "test9" >:: test9;
44
+ "test10" >:: test10;
45
+ ]
46
+
47
+
48
+ (* Running the tests *)
49
+ let () = run_test_tt_main suite
50
+ end
count_beautiful_numbers/scala_tests/MySuite.scala ADDED
@@ -0,0 +1,44 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ class MySuite extends munit.FunSuite {
3
+
4
+ test("test1") {
5
+ assertEquals(Main.beautifulNumbers(10,20), 2)
6
+ }
7
+
8
+ test("test2") {
9
+ assertEquals(Main.beautifulNumbers(1,15), 10)
10
+ }
11
+
12
+ test("test3") {
13
+ assertEquals(Main.beautifulNumbers(915983457,935931314), 12522762)
14
+ }
15
+
16
+ test("test4") {
17
+ assertEquals(Main.beautifulNumbers(380210867,627013516), 169526577)
18
+ }
19
+
20
+ test("test5") {
21
+ assertEquals(Main.beautifulNumbers(433561454,721299239), 196133795)
22
+ }
23
+
24
+ test("test6") {
25
+ assertEquals(Main.beautifulNumbers(199527977,823228058), 425570316)
26
+ }
27
+
28
+ test("test7") {
29
+ assertEquals(Main.beautifulNumbers(447770389,560836489), 76802321)
30
+ }
31
+
32
+ test("test8") {
33
+ assertEquals(Main.beautifulNumbers(389537158,729773416), 232920079)
34
+ }
35
+
36
+ test("test9") {
37
+ assertEquals(Main.beautifulNumbers(586164764,902164574), 213758490)
38
+ }
39
+
40
+ test("test10") {
41
+ assertEquals(Main.beautifulNumbers(928101297,935735179), 4824528)
42
+ }
43
+
44
+ }
count_beautiful_splits_in_an_array/haskell_tests/Main.hs ADDED
The diff for this file is too large to render. See raw diff
 
count_beautiful_splits_in_an_array/java_tests/Main.java ADDED
@@ -0,0 +1,20 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ import static org.junit.jupiter.api.Assertions.*;
3
+ import org.junit.jupiter.api.Test;
4
+ import java.util.List;
5
+ import java.util.Arrays;
6
+ public class Main {
7
+ //Program start
8
+
9
+ //Program end
10
+
11
+ @Test
12
+ public void test1() {
13
+ assertEquals(2, beautifulSplits(Arrays.asList(1,1,2,1)));
14
+ }
15
+ @Test
16
+ public void test2() {
17
+ assertEquals(0, beautifulSplits(Arrays.asList(1,2,3,4)));
18
+ }
19
+
20
+ }
count_beautiful_splits_in_an_array/meta.json ADDED
The diff for this file is too large to render. See raw diff
 
count_beautiful_splits_in_an_array/ocaml_tests/main.ml ADDED
@@ -0,0 +1,42 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ module Main = struct
3
+ open OUnit2
4
+
5
+ (* Program start *)
6
+ let beautifulSplits (nums: int list) : int = failwith "Not implemented"
7
+
8
+ (* Program end *)
9
+
10
+ (* Test cases *)
11
+
12
+ let test1 _ = assert_equal 2 (beautifulSplits [1;1;2;1])
13
+
14
+ let test2 _ = assert_equal 0 (beautifulSplits [1;2;3;4])
15
+
16
+ let test3 _ = assert_equal 0 (beautifulSplits [45; 49; 1; 42; 22; 45; 43; 32; 47; 38; 3; 12; 8; 33; 5; 47; 14; 30; 31; 40; 22; 18; 40; 46; 48; 7; 37; 36; 42; 41; 23; 8; 37; 34; 24; 7; 27; 0; 16; 27; 17; 22; 44; 20; 41; 36; 46; 9; 27; 32; 17; 0; 4; 42; 18; 9; 35; 2; 34; 14; 5; 42; 43; 49; 47; 5; 15; 31; 8; 28; 22; 18; 28; 34; 47; 41; 16; 0; 43; 45; 16; 1; 18; 41; 14; 49; 3; 6; 40; 17; 31; 32; 5; 8; 4; 39; 27; 23; 40; 21; 44; 19; 47; 6; 48; 3; 37; 2; 15; 39; 37; 20; 23; 17; 45; 18; 12; 18; 24; 11; 14; 30; 29; 46; 2; 40; 23; 40; 1; 49; 26; 4; 8; 33; 48; 3; 22; 47; 36; 20; 17; 30; 45; 8; 37; 33; 4; 13; 11; 31; 44; 26; 14; 46; 20; 10; 33; 30; 11; 44; 35; 46; 41; 17; 0; 42; 25; 21; 1; 46; 20; 1; 2; 31; 35; 9; 48; 36; 46; 37; 25; 36; 30; 30; 27; 41; 49; 22; 5; 9; 10; 13; 36; 50; 11; 18; 24; 10; 33; 21; 42; 8; 4; 1; 13; 4; 24; 29; 41; 8; 23; 2; 29; 22; 28; 42; 50; 24; 35; 19; 10; 14; 46; 45; 1; 14; 47; 21; 44; 14; 20; 44; 49; 23; 13; 44; 39; 5; 24; 31; 31; 15; 2; 46; 30; 36; 49; 16; 44; 9; 27; 21; 47; 34; 22; 43; 40; 16; 10; 6; 20; 50; 46; 11; 7; 14; 35; 19; 17; 42; 25; 8; 28; 24; 13; 21; 10; 28; 48; 43; 38; 16; 12; 39; 21; 49; 10; 30; 39; 46; 19; 6; 21; 5; 40; 16; 6; 42; 32; 11; 5; 14; 47; 7; 21; 11; 47; 32; 28; 23; 25; 25; 40; 35; 32; 3; 24; 36; 37; 33; 19; 36; 43; 45; 41; 45; 42; 27; 28; 21; 27; 30; 35; 33; 24; 30; 49; 16; 20; 5; 35; 10; 18; 9; 17; 43; 39; 37; 22; 8; 28; 39; 49; 23; 22; 11; 37; 28; 19; 26; 42; 3; 40; 9; 16; 37; 3; 39; 18; 10; 7; 46; 44; 20; 21; 27; 49; 41; 29; 12; 43; 45; 1; 13; 47; 17; 1; 3; 26; 44; 38; 33; 39; 35; 18; 28; 14; 40; 41; 8; 12; 43; 17; 21; 42; 29; 15; 36; 38; 7; 35; 4; 3; 46; 46; 21; 23; 26; 42; 47; 18; 12; 4; 36; 17; 21; 45; 14; 19; 28; 32; 6; 10; 47; 2; 2; 14; 4; 12; 16; 28; 30; 2; 20; 11; 36; 10; 41; 27; 19; 45; 15; 39; 32; 25; 7; 12; 29; 29; 33; 11; 7; 19; 48; 21; 26; 28; 24; 31; 31; 30; 21; 23; 8; 36; 38; 9; 26; 23; 25; 13; 30; 47; 2; 30; 49; 42; 35; 30; 28; 39; 9; 17; 22; 24; 47; 28; 9; 40; 18; 28; 0; 6; 49; 45; 18; 20; 18; 28; 11; 27; 35; 25; 35; 47; 9; 47; 8; 3; 2; 15; 27; 3; 45; 11; 43; 3; 13; 13; 14; 42; 14; 23; 0; 16; 15; 9; 32; 7; 4; 29; 36; 43; 24; 11; 40; 44; 22; 5; 48; 11; 50; 35; 42; 43; 29; 10; 11; 50; 25; 24; 49; 50; 28; 0; 40; 32; 4; 7; 40; 37; 50; 5; 12; 0; 24; 38; 40; 49; 26; 5; 7; 16; 21; 30; 19; 27; 1; 25; 40; 40; 45; 19; 12; 2; 32; 15; 41; 9; 46; 1; 29; 31; 6; 20; 44; 50; 19; 9; 25; 47; 18; 47; 39; 20; 18; 10; 31; 35; 6; 14; 12; 29; 0; 20; 9; 12; 29; 9; 47; 24; 24; 38; 44; 3; 18; 42; 13; 28; 18; 45; 18; 14; 13; 4; 32; 12; 21; 45; 15; 50; 9; 39; 36; 7; 25; 33; 12; 39; 38; 34; 7; 12; 22; 19; 8; 7; 36; 12; 31; 30; 16; 3; 6; 0; 47; 12; 31; 47; 2; 27; 1; 33; 48; 4; 44; 2; 24; 12; 26; 35; 39; 26; 25; 19; 4; 9; 14; 33; 3; 6; 5; 34; 5; 17; 19; 29; 30; 15; 33; 22; 47; 15; 35; 3; 1; 32; 31; 31; 2; 37; 18; 38; 3; 13; 31; 33; 24; 42; 20; 5; 15; 21; 36; 30; 38; 30; 31; 1; 5; 16; 21; 46; 2; 11; 49; 41; 26; 39; 44; 43; 1; 24; 20; 50; 13; 35; 8; 16; 48; 28; 44; 18; 10; 3; 28; 6; 40; 6; 33; 38; 43; 25; 12; 21; 45; 33; 29; 10; 20; 24; 8; 4; 39; 44; 3; 41; 31; 47; 49; 30; 13; 48; 21; 7; 13; 29; 37; 49; 15; 28; 12; 26; 43; 46; 42; 22; 2; 36; 49; 46; 41; 6; 29; 25; 48; 26; 20; 26; 5; 35; 48; 32; 41; 12; 42; 42; 34; 4; 35; 33; 48; 12; 40; 6; 20; 34; 9; 35; 30; 19; 9; 30; 4; 40; 37; 21; 40; 37; 37; 43; 3; 26; 7; 28; 6; 22; 27; 14; 1; 26; 50; 25; 9; 37; 8; 29; 22; 46; 38; 17; 0; 22; 33; 23; 20; 16; 42; 49; 25; 32; 10; 38; 4; 45; 47; 29; 18; 33; 1; 42; 19; 29; 17; 39; 23; 14; 9; 26; 33; 34; 19; 6; 22; 9; 7; 26; 12; 38; 4; 31; 18; 11; 21; 47; 11; 1; 5; 28; 16; 46; 32; 46; 22; 23; 27; 0; 23; 45; 6; 48; 25; 17; 42; 40; 38; 43; 50; 49; 2; 24; 33; 47; 49; 26; 29; 8; 21; 47; 29; 23; 50; 8; 39; 45; 42; 49; 13; 41; 48; 3; 37; 5; 12; 35; 43; 40; 26; 30; 28; 36; 24; 40; 26; 50; 2; 6; 15; 31; 46; 30; 21; 35; 3; 19; 6; 14; 4; 25; 25; 18; 4; 39; 5; 29; 30; 46; 9; 50; 24; 10; 8; 50; 41; 8; 14; 4; 34; 31; 41; 45; 29; 37; 25; 40; 23; 30; 2; 5; 42; 16; 16; 8; 10; 10; 18; 49; 25; 37; 5; 48; 2; 39; 47; 39; 36; 26; 11; 6; 43; 30; 11; 48; 10; 32; 37; 14; 20; 47; 40; 9; 14; 8; 20; 5; 35; 22; 48; 27; 34; 2; 15; 21; 44; 11; 22; 40; 11; 27; 32; 23; 41; 33; 16; 31; 38; 18; 39; 45; 1; 40; 24; 20; 33; 4; 23; 42; 37; 14; 9; 36; 35; 38; 49; 2; 11; 43; 31; 17; 31; 8; 0; 14; 31; 37; 26; 50; 6; 48; 41; 18; 46; 47; 45; 4; 10; 12; 19; 0; 44; 45; 7; 38; 8; 9; 38; 24; 46; 37; 3; 16; 8; 8; 2; 46; 48; 12; 19; 38; 8; 22; 7; 1; 32; 43; 16; 16; 15; 40; 31; 12; 26; 25; 46; 20; 6; 31; 29; 29; 47; 32; 17; 31; 37; 25; 26; 28; 1; 44; 19; 7; 39; 39; 22; 30; 9; 37; 19; 2; 34; 2; 50; 12; 35; 27; 16; 33; 5; 35; 30; 25; 4; 20; 8; 1; 10; 43; 50; 32; 10; 39; 14; 24; 32; 4; 14; 0; 14; 47; 31; 16; 15; 11; 33; 35; 33; 34; 6; 28; 26; 32; 8; 3; 32; 40; 42; 31; 22; 38; 48; 0; 39; 10; 37; 48; 43; 41; 0; 43; 3; 35; 35; 11; 12; 34; 4; 42; 16; 18; 30; 36; 36; 25; 3; 17; 46; 42; 48; 42; 47; 22; 34; 31; 10; 26; 7; 38; 15; 6; 21; 7; 7; 46; 46; 7; 21; 23; 27; 49; 30; 29; 21; 1; 46; 10; 3; 38; 38; 38; 9; 43; 0; 12; 0; 3; 18; 28; 16; 9; 26; 46; 8; 12; 38; 34; 25; 30; 31; 13; 2; 26; 36; 49; 27; 23; 17; 46; 26; 33; 26; 22; 44; 21; 4; 42; 12; 27; 35; 21; 42; 46; 12; 20; 46; 40; 39; 7; 26; 17; 19; 37; 10; 22; 45; 35; 4; 9; 35; 28; 13; 2; 36; 46; 30; 25; 2; 41; 27; 28; 14; 47; 43; 36; 39; 31; 34; 24; 3; 50; 30; 7; 27; 14; 29; 30; 33; 40; 49; 45; 41; 8; 38; 41; 49; 0; 26; 43; 48; 13; 34; 45; 32; 46; 12; 0; 1; 11; 14; 48; 15; 14; 17; 19; 13; 41; 23; 8; 25; 46; 36; 47; 43; 8; 2; 15; 32; 15; 16; 13; 39; 23; 3; 45; 34; 22; 7; 19; 11; 40; 18; 29; 34; 48; 18; 25; 33; 7; 14; 2; 21; 46; 37; 2; 24; 15; 6; 21; 46; 8; 17; 14; 27; 29; 46; 48; 43; 30; 25; 30; 33; 50; 25; 21; 39; 42; 5; 11; 50; 38; 4; 16; 46; 7; 34; 37; 12; 41; 14; 15; 46; 1; 26; 16; 27; 21; 43; 23; 27; 42; 35; 28; 1; 32; 9; 17; 32; 13; 36; 26; 37; 30; 12; 50; 18; 39; 10; 11; 36; 10; 32; 35; 9; 32; 4; 46; 26; 13; 14; 30; 25; 44; 22; 37; 11; 24; 1; 7; 21; 47; 38; 2; 10; 27; 6; 41; 29; 0; 22; 22; 40; 16; 13; 31; 21; 22; 22; 32; 30; 14; 42; 8; 50; 10; 17; 4; 7; 36; 40; 45; 43; 36; 42; 17; 26; 32; 29; 46; 8; 17; 46; 40; 24; 28; 28; 45; 4; 14; 28; 30; 9; 39; 39; 19; 1; 29; 38; 5; 36; 14; 0; 27; 25; 29; 22; 10; 37; 27; 37; 23; 5; 23; 40; 43; 48; 6; 18; 28; 4; 12; 5; 30; 49; 40; 45; 10; 15; 50; 26; 37; 27; 32; 29; 22; 8; 43; 39; 22; 16; 27; 4; 41; 31; 39; 26; 31; 28; 34; 50; 10; 2; 15; 50; 14; 23; 40; 44; 49; 29; 16; 38; 25; 2; 15; 11; 33; 10; 22; 26; 42; 19; 24; 21; 38; 38; 4; 35; 23; 9; 9; 6; 18; 19; 30; 34; 43; 48; 45; 47; 31; 2; 13; 16; 17; 22; 45; 26; 48; 44; 8; 9; 28; 32; 17; 34; 17; 25; 27; 49; 44; 30; 39; 12; 44; 28; 15; 5; 9; 19; 31; 26; 19; 32; 0; 21; 13; 6; 2; 24; 36; 25; 5; 33; 12; 47; 20; 38; 31; 37; 7; 23; 47; 44; 0; 26; 45; 47; 1; 35; 32; 5; 29; 5; 20; 44; 18; 34; 5; 39; 42; 16; 41; 5; 31; 2; 36; 46; 13; 30; 25; 43; 36; 21; 21; 47; 50; 43; 35; 19; 26; 21; 28; 16; 18; 25; 49; 36; 9; 11; 9; 8; 25; 18; 48; 45; 28; 2; 17; 50; 10; 34; 17; 15; 19; 5; 22; 45; 23; 48; 45; 30; 46; 36; 16; 46; 9; 31; 28; 15; 42; 50; 6; 5; 20; 7; 20; 50; 46; 29; 0; 0; 37; 13; 50; 37; 43; 47; 13; 10; 0; 27; 38; 7; 31; 19; 41; 25; 48; 45; 32; 23; 10; 45; 32; 30; 0; 21; 32; 4; 35; 21; 47; 45; 11; 1; 35; 14; 5; 27; 31; 5; 38; 18; 30; 47; 43; 30; 19; 16; 49; 34; 24; 7; 44; 47; 36; 15; 28; 14; 48; 44; 10; 19; 47; 9; 45; 32; 16; 0; 30; 13; 37; 20; 50; 8; 4; 50; 43; 22; 0; 24; 46; 28; 39; 20; 10; 50; 46; 9; 20; 19; 47; 27; 7; 1; 6; 7; 34; 3; 16; 37; 35; 21; 48; 29; 25; 9; 16; 41; 42; 28; 48; 44; 7; 2; 19; 35; 38; 8; 14; 2; 34; 36; 50; 13; 32; 47; 18; 9; 15; 47; 0; 6; 6; 30; 0; 3; 19; 48; 39; 12; 19; 20; 15; 30; 17; 44; 21; 21; 20; 15; 1; 2; 29; 45; 16; 4; 35; 31; 15; 34; 37; 45; 22; 27; 8; 36; 4; 38; 14; 16; 49; 12; 21; 35; 37; 42; 11; 46; 9; 32; 30; 35; 27; 14; 7; 46; 1; 27; 14; 0; 14; 16; 4; 5; 28; 45; 1; 27; 25; 23; 31; 27; 17; 41; 23; 50; 38; 48; 35; 41; 15; 32; 43; 3; 39; 10; 29; 28; 7; 15; 40; 49; 3; 45; 41; 34; 30; 31; 43; 11; 26; 28; 27; 46; 46; 24; 37; 35; 41; 8; 34; 17; 11; 32; 8; 42; 27; 1; 38; 12; 37; 32; 40; 38; 20; 43; 45; 44; 5; 31; 1; 12; 37; 38; 6; 50; 39; 22; 25; 30; 14; 19; 23; 25; 1; 8; 11; 31; 49; 13; 50; 28; 37; 42; 24; 17; 34; 14; 48; 8; 50; 13; 49; 41; 6; 25; 6; 26; 41; 50; 40; 10; 12; 20; 22; 27; 18; 7; 10; 44; 42; 6; 26; 47; 15; 26; 16; 24; 14; 24; 40; 10; 9; 10; 45; 8; 10; 45; 2; 41; 10; 23; 44; 33; 31; 1; 1; 8; 11; 10; 32; 6; 24; 43; 9; 40; 43; 46; 34; 12; 27; 38; 14; 13; 10; 17; 24; 47; 10; 31; 21; 44; 45; 4; 14; 11; 19; 24; 23; 13; 49; 23; 46; 22; 25; 25; 8; 11; 46; 50; 3; 21; 0; 12; 16; 2; 3; 45; 1; 0; 8; 31; 31; 40; 14; 1; 8; 41; 2; 7; 31; 7; 8; 2; 30; 29; 38; 39; 43; 18; 24; 42; 38; 49; 3; 32; 17; 3; 37; 34; 13; 35; 3; 16; 22; 16; 2; 23; 10; 12; 37; 19; 15; 16; 17; 48; 6; 10; 25; 35; 4; 29; 12; 36; 34; 25; 15; 11; 47; 2; 7; 29; 7; 22; 23; 7; 25; 4; 26; 20; 3; 48; 14; 3; 15; 44; 37; 12; 5; 25; 32; 26; 10; 25; 44; 2; 50; 4; 2; 39; 16; 23; 3; 1; 4; 11; 6; 32; 35; 7; 34; 6; 31; 37; 7; 40; 0; 15; 1; 9; 28; 29; 0; 22; 22; 14; 31; 41; 0; 15; 42; 15; 40; 20; 50; 45; 26; 27; 29; 33; 29; 18; 33; 24; 0; 12; 44; 47; 4; 1; 2; 8; 44; 24; 0; 47; 39; 34; 27; 34; 7; 6; 47; 18; 41; 11; 11; 25; 22; 46; 11; 14; 26; 4; 32; 29; 16; 29; 47; 14; 36; 23; 14; 11; 50; 4; 1; 24; 42; 23; 13; 47; 44; 38; 18; 1; 14; 34; 36; 18; 14; 17; 41; 23; 16; 45; 19; 16; 38; 49; 39; 20; 2; 35; 3; 12; 21; 26; 17; 34; 32; 32; 5; 46; 10; 30; 47; 48; 31; 8; 5; 50; 17; 44; 26; 2; 30; 40; 39; 46; 13; 33; 36; 47; 0; 20; 33; 46; 31; 13; 28; 46; 37; 35; 7; 39; 23; 28; 5; 10; 21; 31; 47; 18; 22; 44; 0; 12; 34; 15; 37; 35; 34; 12; 22; 34; 37; 7; 43; 1; 14; 28; 46; 39; 0; 42; 26; 12; 9; 8; 40; 19; 7; 5; 32; 14; 19; 15; 15; 50; 22; 31; 38; 19; 18; 18; 2; 47; 36; 7; 3; 19; 3; 9; 25; 4; 3; 25; 14; 12; 1; 13; 21; 29; 36; 21; 17; 46; 27; 16; 2; 9; 41; 39; 29; 23; 21; 20; 49; 32; 2; 32; 40; 30; 43; 14; 17; 27; 45; 16; 31; 25; 40; 26; 18; 35; 40; 36; 24; 32; 39; 1; 24; 8; 39; 13; 5; 50; 13; 34; 18; 33; 16; 48; 10; 13; 40; 27; 14; 15; 37; 49; 0; 24; 3; 13; 10; 46; 9; 20; 31; 20; 35; 38; 35; 5; 9; 20; 47; 8; 4; 25; 44; 5; 22; 28; 14; 40; 42; 18; 9; 14; 40; 29; 20; 25; 4; 32; 34; 6; 24; 9; 39; 29; 21; 38; 19; 19; 4; 15; 23; 37; 33; 29; 33; 25; 0; 14; 4; 41; 50; 19; 27; 4; 9; 37; 16; 5; 7; 24; 2; 23; 12; 19; 30; 25; 42; 4; 0; 31; 44; 9; 38; 40; 11; 28; 44; 43; 9; 50; 2; 11; 29; 47; 7; 8; 39; 32; 22; 14; 13; 5; 35; 48; 10; 30; 28; 12; 2; 25; 29; 23; 19; 16; 23; 24; 9; 25; 38; 50; 36; 2; 44; 35; 7; 3; 15; 50; 21; 49; 42; 32; 5; 9; 7; 8; 48; 34; 41; 21; 39; 15; 2; 13; 35; 47; 2; 22; 2; 2; 16; 12; 16; 28; 43; 37; 12; 37; 26; 22; 19; 41; 28; 24; 20; 43; 19; 47; 50; 13; 28; 43; 17; 13; 33; 11; 34; 28; 16; 48; 24; 49; 23; 9; 11; 15; 48; 7; 16; 50; 23; 45; 14; 44; 1; 31; 39; 43; 17; 49; 28; 6; 28; 34; 13; 11; 9; 7; 25; 20; 19; 39; 40; 7; 6; 18; 18; 18; 36; 15; 28; 37; 42; 26; 18; 37; 12; 3; 36; 0; 45; 1; 29; 35; 31; 20; 33; 42; 2; 9; 2; 42; 46; 24; 17; 29; 17; 1; 49; 26; 32; 36; 9; 23; 46; 47; 35; 46; 47; 11; 30; 15; 1; 47; 49; 10; 25; 29; 12; 28; 13; 36; 50; 36; 11; 30; 50; 22; 1; 13; 6; 2; 8; 3; 14; 26; 4; 35; 9; 42; 6; 47; 17; 39; 46; 3; 19; 44; 23; 39; 14; 34; 48; 24; 4; 20; 50; 41; 9; 43; 41; 10; 37; 29; 42; 40; 37; 0; 32; 10; 21; 17; 11; 17; 7; 38; 27; 11; 41; 43; 25; 35; 3])
17
+
18
+ let test4 _ = assert_equal 0 (beautifulSplits [43; 13; 15; 5; 4; 43; 7; 6; 22; 28; 34; 41; 26; 38; 37; 23; 41; 15; 5; 35; 41; 8; 21; 14; 12; 30; 16; 49; 10; 47; 2; 43; 24; 19; 50; 47; 9; 29; 28; 45; 31; 39; 16; 45; 1; 30; 18; 13; 15; 2; 9; 11; 32; 32; 32; 26; 47; 22; 4; 18; 26; 38; 41; 39; 39; 37; 40; 1; 16; 10; 30; 13; 25; 34; 6; 7; 12; 25; 14; 4; 2; 3; 38; 40; 20; 32; 26; 20; 17; 7; 1; 12; 44; 49; 47; 5; 20; 6; 15; 3; 29; 8; 50; 4; 0; 43; 29; 45; 27; 14; 43; 18; 23; 37; 29; 35; 21; 23; 49; 45; 3; 48; 43; 22; 2; 3; 21; 20; 25; 27; 46; 22; 0; 21; 7; 40; 46; 8; 19; 43; 7; 50; 2; 32; 5; 15; 44; 32; 16; 29; 21; 32; 0; 36; 9; 10; 14; 44; 25; 13; 5; 25; 11; 33; 4; 2; 47; 32; 35; 35; 34; 10; 8; 17; 1; 9; 31; 43; 11; 19; 31; 21; 25; 16; 17; 15; 47; 32; 48; 30; 47; 3; 6; 23; 24; 6; 6; 33; 1; 47; 9; 7; 42; 10; 34; 17; 21; 27; 3; 50; 10; 41; 12; 27; 17; 14; 19; 14; 19; 26; 29; 32; 7; 0; 45; 18; 0; 12; 4; 29; 7; 44; 43; 14; 35; 13; 26; 26; 42; 15; 44; 41; 3; 37; 23; 7; 23; 32; 18; 35; 2; 46; 2; 47; 14; 29; 48; 21; 13; 43; 34; 50; 11; 47; 36; 10; 19; 32; 6; 4; 19; 4; 27; 17; 13; 13; 13; 32; 17; 15; 22; 36; 12; 21; 29; 16; 29; 18; 28; 37; 46; 43; 33; 28; 43; 17; 13; 31; 22; 35; 21; 13; 4; 43; 7; 11; 26; 16; 7; 8; 36; 6; 12; 15; 11; 40; 34; 35; 17; 13; 28; 49; 35; 20; 14; 31; 45; 39; 13; 17; 15; 48; 41; 21; 48; 18; 36; 24; 22; 1; 44; 14; 17; 4; 13; 17; 9; 47; 42; 29; 8; 19; 10; 36; 17; 49; 24; 48; 26; 26; 22; 13; 40; 27; 7; 26; 37; 40; 20; 11; 18; 39; 19; 30; 1; 27; 45; 29; 48; 43; 24; 35; 8; 39; 11; 10; 5; 8; 11; 25; 33; 25; 44; 15; 27; 12; 21; 31; 38; 42; 36; 10; 11; 25; 19; 22; 30; 0; 33; 11; 16; 0; 46; 28; 34; 31; 21; 40; 32; 28; 50; 46; 41; 11; 7; 16; 18; 4; 8; 47; 39; 29; 40; 41; 21; 15; 39; 5; 31; 11; 28; 21; 39; 40; 29; 42; 23; 38; 45; 44; 17; 41; 21; 43; 17; 46; 17; 45; 50; 16; 26; 19; 9; 3; 11; 3; 33; 47; 32; 18; 39; 31; 20; 2; 13; 32; 34; 9; 14; 6; 32; 49; 5; 16; 21; 25; 33; 32; 34; 4; 19; 2; 31; 2; 13; 45; 29; 37; 46; 4; 2; 18; 24; 2; 48; 42; 44; 46; 21; 49; 26; 3; 22; 24; 44; 45; 36; 27; 21; 16; 35; 49; 31; 26; 46; 1; 45; 44; 3; 18; 20; 15; 44; 31; 38; 46; 16; 20; 44; 44; 48; 41; 8; 36; 1; 2; 40; 44; 21; 33; 16; 26; 49; 9; 12; 6; 33; 41; 33; 8; 45; 37; 48; 37; 12; 40; 41; 27; 1; 1; 7; 7; 45; 24; 0; 48; 8; 16; 32; 21; 34; 46; 46; 9; 38; 43; 7; 33; 38; 2; 41; 40; 1; 13; 47; 33; 47; 22; 48; 46; 34; 32; 44; 8; 41; 13; 20; 22; 23; 27; 27; 18; 14; 21; 12; 30; 17; 6; 22; 11; 5; 21; 35; 39; 39; 22; 2; 38; 7; 35; 22; 47; 21; 32; 19; 25; 4; 13; 31; 18; 41; 12; 41; 40; 13; 12; 12; 7; 2; 10; 10; 5; 13; 10; 2; 42; 17; 46; 43; 19; 4; 27; 33; 48; 28; 42; 36; 34; 7; 22; 28; 38; 20; 10; 39; 29; 42; 34; 11; 10; 10; 7; 11; 8; 10; 49; 4; 40; 35; 10; 2; 11; 41; 21; 28; 2; 21; 34; 19; 3; 21; 28; 40; 10; 16; 15; 25; 0; 3; 22; 2; 34; 33; 13; 0; 3; 4; 12; 29; 19; 45; 28; 41; 40; 33; 13; 15; 33; 8; 38; 39; 31; 26; 48; 35; 18; 46; 32; 43; 32; 7; 32; 11; 25; 0; 30; 10; 10; 18; 49; 30; 49; 30; 39; 48; 50; 1; 6; 9; 44; 4; 33; 37; 28; 11; 10; 5; 1; 22; 0; 3; 16; 13; 17; 18; 9; 12; 40; 14; 46; 42; 49; 31; 50; 49; 6; 11; 23; 44; 29; 42; 6; 43; 20; 23; 48; 38; 26; 39; 12; 43; 13; 20; 32; 8; 0; 24; 50; 43; 9; 23; 49; 26; 19; 24; 42; 7; 24; 18; 22; 48; 35; 7; 1; 6; 46; 37; 35; 4; 29; 35; 21; 0; 32; 39; 5; 44; 14; 11; 45; 13; 47; 24; 29; 20; 19; 31; 9; 20; 38; 34; 3; 38; 34; 33; 48; 10; 20; 33; 20; 11; 12; 47; 34; 44; 46; 44; 9; 31; 14; 42; 17; 22; 25; 9; 43; 33; 6; 24; 49; 24; 38; 34; 13; 2; 25; 12; 28; 32; 19; 21; 0; 8; 45; 50; 11; 36; 0; 32; 15; 30; 3; 18; 20; 46; 7; 24; 24; 47; 8; 7; 47; 28; 27; 29; 25; 0; 16; 15; 37; 20; 36; 5; 32; 50; 41; 44; 10; 29; 23; 49; 21; 13; 19; 32; 16; 44; 8; 9; 40; 47; 42; 24; 38; 31; 49; 28; 40; 44; 2; 7; 25; 37; 23; 8; 11; 12; 7; 41; 23; 29; 12; 4; 6; 38; 26; 5; 15; 28; 19; 13; 50; 29; 31; 48; 39; 18; 38; 30; 21; 7; 14; 8; 3; 49; 11; 10; 2; 35; 22; 9; 20; 40; 6; 37; 32; 26; 24; 22; 13; 41; 29; 15; 30; 10; 12; 47; 18; 15; 10; 5; 20; 36; 49; 0; 35; 17; 3; 44; 46; 16; 2; 2; 20; 1; 13; 31; 30; 39; 5; 47; 31; 5; 35; 43; 28; 21; 4; 49; 9; 25; 46; 1; 37; 16; 42; 32; 34; 5; 43; 24; 14; 48; 9; 32; 16; 44; 0; 9; 28; 39; 12; 4; 31; 20; 4; 7; 2; 45; 15; 7; 37; 43; 31; 31; 17; 29; 22; 20; 25; 11; 30; 46; 3; 42; 13; 47; 38; 6; 0; 17; 45; 3; 3; 1; 9; 36; 26; 45; 43; 14; 1; 32; 16; 10; 44; 19; 24; 5; 33; 1; 7; 44; 10; 40; 47; 7; 3; 34; 34; 28; 8; 37; 28; 41; 41; 12; 19; 34; 18; 11; 30; 4; 36; 4; 23; 9; 40; 31; 12; 37; 22; 23; 17; 50; 48; 0; 9; 45; 16; 46; 6; 47; 3; 48; 42; 48; 11; 30; 21; 39; 46; 29; 29; 36; 45; 29; 49; 34; 25; 34; 13; 40; 19; 14; 4; 21; 23; 9; 14; 5; 13; 38; 6; 43; 22; 34; 13; 21; 33; 8; 46; 30; 44; 17; 29; 43; 48; 23; 42; 21; 7; 8; 21; 4; 32; 19; 25; 1; 10; 3; 35; 4; 49; 40; 23; 41; 23; 10; 28; 10; 31; 7; 39; 38; 47; 20; 29; 20; 6; 23; 24; 31; 23; 7; 7; 39; 31; 29; 11; 1; 31; 27; 36; 28; 2; 42; 45; 50; 4; 19; 43; 42; 26; 0; 40; 12; 6; 23; 48; 3; 37; 8; 50; 46; 17; 46; 35; 23; 1; 31; 25; 7; 11; 43; 24; 40; 31; 37; 47; 11; 43; 3; 7; 38; 8; 47; 40; 47; 25; 26; 4; 5; 19; 41; 41; 21; 23; 18; 39; 44; 46; 9; 28; 25; 38; 49; 15; 46; 43; 45; 28; 13; 3; 2; 16; 22; 29; 36; 50; 42; 48; 44; 47; 9; 32; 34; 17; 45; 3; 40; 25; 35; 43; 16; 9; 26; 27; 15; 10; 14; 7; 33; 23; 50; 1; 1; 0; 14; 26; 15; 38; 8; 22; 30; 23; 9; 50; 49; 5; 47; 15; 21; 31; 6; 41; 8; 26; 48; 34; 0; 20; 37; 33; 44; 1; 3; 35; 45; 40; 34; 18; 46; 10; 9; 39; 29; 42; 47; 12; 5; 11; 25; 9; 50; 24; 33; 27; 34; 25; 38; 48; 17; 38; 7; 31; 42; 33; 38; 47; 46; 40; 22; 0; 10; 1; 8; 8; 22; 29; 4; 32; 26; 4; 38; 10; 24; 11; 28; 23; 49; 16; 12; 13; 15; 30; 3; 24; 39; 40; 11; 48; 40; 25; 17; 48; 42; 49; 24; 3; 2; 15; 39; 34; 38; 34; 41; 4; 40; 11; 30; 7; 31; 19; 16; 19; 49; 22; 2; 15; 20; 2; 30; 38; 33; 11; 37; 49; 48; 46; 27; 36; 25; 47; 8; 15; 48; 2; 0; 45; 43; 36; 26; 34; 3; 18; 34; 31; 30; 7; 22; 2; 34; 46; 33; 15; 36; 44; 31; 38; 47; 43; 50; 24; 46; 9; 11; 10; 22; 4; 14; 25; 16; 27; 38; 0; 42; 7; 18; 22; 23; 2; 31; 27; 28; 48; 34; 31; 47; 35; 21; 45; 40; 7; 35; 42; 23; 44; 16; 6; 24; 40; 38; 37; 46; 4; 39; 37; 30; 5; 31; 30; 11; 26; 47; 40; 11; 22; 37; 4; 17; 4; 42; 9; 49; 14; 47; 9; 24; 18; 6; 37; 2; 2; 39; 31; 13; 29; 50; 32; 25; 5; 16; 34; 46; 30; 32; 45; 10; 44; 10; 3; 44; 2; 48; 7; 38; 44; 46; 39; 6; 9; 32; 33; 48; 16; 3; 35; 43; 27; 15; 22; 1; 19; 4; 16; 10; 8; 27; 23; 0; 50; 10; 37; 43; 42; 25; 16; 25; 15; 32; 28; 34; 15; 11; 49; 7; 17; 0; 33; 0; 42; 27; 5; 1; 16; 11; 40; 46; 38; 23; 37; 44; 18; 6; 8; 41; 2; 38; 45; 33; 45; 15; 8; 42; 15; 4; 37; 45; 18; 28; 16; 50; 26; 40; 38; 21; 32; 20; 33; 40; 25; 30; 1; 27; 38; 1; 35; 20; 33; 11; 48; 2; 37; 27; 13; 31; 9; 8; 27; 47; 41; 32; 43; 24; 28; 40; 17; 35; 15; 38; 28; 35; 35; 37; 20; 29; 31; 26; 11; 13; 41; 29; 16; 24; 50; 36; 35; 39; 26; 17; 27; 48; 28; 13; 42; 15; 22; 44; 7; 50; 29; 19; 2; 38; 30; 33; 44; 22; 20; 13; 37; 10; 27; 48; 22; 47; 45; 0; 2; 47; 5; 45; 10; 1; 8; 16; 40; 10; 50; 23; 25; 40; 27; 39; 24; 36; 37; 31; 48; 46; 11; 37; 24; 50; 9; 4; 15; 47; 39; 34; 46; 14; 6; 1; 11; 16; 13; 29; 4; 47; 21; 47; 41; 41; 13; 3; 48; 32; 21; 7; 15; 10; 31; 23; 48; 40; 25; 37; 5; 46; 39; 5; 6; 48; 47; 17; 2; 20; 30; 43; 12; 46; 46; 14; 41; 7; 33; 45; 46; 35; 14; 0; 44; 7; 27; 34; 5; 6; 6; 3; 31; 27; 23; 33; 29; 46; 16; 42; 4; 4; 42; 3; 2; 40; 7; 34; 23; 20; 17; 17; 5; 23; 41; 50; 45; 37; 27; 11; 50; 12; 19; 9; 7; 20; 44; 50; 38; 13; 20; 1; 42; 3; 1; 21; 11; 25; 23; 27; 33; 49; 22; 10; 23; 15; 49; 3; 11; 41; 37; 15; 42; 5; 25; 44; 46; 11; 6; 2; 1; 50; 36; 34; 36; 36; 32; 29; 26; 12; 26; 27; 4; 15; 40; 49; 26; 41; 46; 45; 20; 50; 12; 0; 12; 4; 2; 17; 37; 5; 36; 41; 32; 6; 49; 4; 49; 1; 11; 42; 50; 31; 18; 18; 32; 27; 47; 49; 22; 25; 3; 12; 48; 46; 28; 0; 37; 26; 18; 29; 49; 33; 20; 36; 41; 27; 3; 15; 21; 17; 34; 50; 34; 6; 13; 33; 41; 21; 44; 29; 30; 27; 4; 15; 30; 25; 41; 9; 50; 12; 42; 4; 22; 35; 4; 28; 27; 22; 13; 34; 23; 10; 14; 1; 1; 31; 13; 8; 22; 30; 23; 38; 11; 6; 10; 32; 25; 39; 6; 35; 26; 38; 23; 17; 46; 42; 17; 14; 41; 1; 30; 3; 15; 27; 48; 18; 33; 3; 6; 8; 13; 1; 26; 25; 12; 33; 13; 39; 40; 45; 1; 27; 16; 44; 25; 19; 6; 25; 34; 41; 31; 18; 14; 5; 35; 44; 18; 25; 33; 24; 21; 47; 45; 26; 2; 4; 43; 20; 43; 22; 9; 37; 22; 25; 35; 25; 24; 22; 9; 8; 39; 45; 19; 25; 41; 21; 45; 15; 46; 34; 31; 26; 37; 10; 22; 39; 47; 37; 14; 0; 26; 20; 13; 8; 48; 1; 9; 12; 47; 20; 26; 50; 41; 35; 15; 50; 34; 40; 36; 11; 23; 24; 11; 0; 20; 28; 18; 7; 23; 3; 29; 6; 50; 39; 30; 10; 12; 18; 1; 1; 38; 31; 32; 11; 9; 1; 35; 12; 4; 35; 49; 43; 32; 14; 38; 43; 0; 45; 29; 7; 15; 35; 0; 44; 17; 26; 7; 16; 38; 29; 30; 3; 43; 14; 46; 3; 48; 49; 38; 9; 30; 21; 25; 19; 15; 9; 0; 14; 37; 35; 46; 19; 38; 15; 10; 48; 23; 0; 39; 22; 35; 14; 26; 30; 2; 42; 38; 13; 6; 35; 4; 4; 41; 18; 43; 25; 0; 41; 31; 47; 4; 35; 32; 27; 27; 19; 33; 24; 19; 35; 39; 25; 15; 40; 16; 21; 27; 0; 4; 25; 7; 16; 32; 26; 8; 23; 5; 7; 25; 29; 18; 10; 38; 33; 37; 7; 48; 5; 25; 8; 8; 7; 35; 21; 50; 32; 19; 36; 31; 6; 21; 14; 15; 46; 13; 29; 5; 24; 10; 25; 46; 18; 3; 40; 17; 11; 37; 11; 18; 22; 37; 8; 15; 12; 20; 14; 31; 32; 12; 10; 41; 38; 11; 24; 32; 32; 37; 5; 16; 5; 46; 47; 41; 36; 41; 35; 41; 12; 44; 20; 43; 23; 14; 39; 41; 2; 47; 26; 40; 37; 29; 0; 23; 37; 49; 39; 18; 28; 25; 14; 3; 10; 4; 2; 4; 14; 40; 38; 29; 35; 14; 21; 12; 45; 5; 41; 38; 43; 34; 43; 46; 22; 42; 44; 35; 40; 24; 48; 31; 9; 2; 43; 13; 42; 21; 41; 21; 10; 39; 26; 22; 26; 4; 20; 10; 36; 36; 37; 10; 17; 4; 41; 0; 39; 18; 42; 29; 8; 1; 24; 48; 37; 36; 45; 24; 48; 49; 15; 42; 43; 13; 34; 10; 30; 19; 32; 5; 29; 10; 50; 5; 12; 21; 17; 15; 15; 34; 30; 24; 45; 22; 18; 37; 50; 20; 18; 22; 34; 19; 31; 20; 48; 38; 17; 22; 27; 12; 41; 18; 45; 43; 0; 15; 34; 6; 44; 0; 46; 16; 12; 35; 39; 12; 33; 33; 31; 9; 31; 17; 46; 3; 36; 42; 23; 5; 7; 43; 1; 24; 42; 30; 27; 10; 45; 18; 27; 23; 26; 8; 6; 6; 42; 13; 46; 28; 21; 50; 3; 19; 14; 42; 5; 39; 15; 50; 2; 20; 13; 38; 29; 7; 23; 11; 47; 40; 27; 36; 38; 38; 38; 41; 11; 5; 38; 42; 21; 39; 31; 27; 9; 40; 2; 25; 5; 11; 31; 35; 25; 4; 22; 44; 27; 36; 41; 39; 14; 10; 14; 29; 34; 38; 19; 17; 14; 17; 49; 40; 18; 14; 49; 50; 22; 4; 31; 43; 26; 3; 0; 20; 48; 2; 18; 40; 17; 29; 14; 29; 34; 13; 22; 29; 1; 24; 17; 20; 42; 11; 41; 38; 6; 32; 6; 49; 46; 25; 4; 43; 33; 41; 9; 49; 23; 17; 29; 35; 23; 12; 35; 44; 37; 3; 21; 14; 45; 37; 21; 41; 41; 35; 23; 20; 0; 32; 21; 40; 15; 48; 31; 37; 32; 13; 35; 15; 7; 2; 4; 45; 48; 16; 15; 48; 45; 33; 14; 12; 50; 39; 6; 31; 0; 23; 21; 23; 41; 5; 45; 1; 2; 24; 29; 3; 27; 21; 48; 17; 24; 16; 15; 16; 10; 36; 26; 5; 14; 7; 5; 9; 12; 31; 3; 8; 50; 45; 3; 9; 7; 14; 42; 2; 39; 11; 8; 29; 21; 4; 12; 15; 21; 34; 13; 16; 11; 9; 18; 34; 42; 16; 6; 26; 48; 11; 2; 26; 34; 44; 34; 14; 7; 7; 42; 2; 30; 23; 21; 2; 43; 16; 36; 49; 28; 7; 39; 2; 20; 0; 3; 32; 16; 2; 32; 29; 39; 15; 12; 24; 50; 0; 21; 42; 8; 3; 44; 18; 35; 14; 25; 8; 40; 45; 29; 43; 12; 3; 11; 34; 24; 13; 9; 7; 28; 27; 44; 40; 48; 37; 7; 0; 43; 48; 6; 24; 10; 28; 38; 48; 36; 40; 30; 36; 49; 26; 0; 5; 35; 27; 36; 12; 13; 16; 37; 43; 38; 3; 22; 32; 9; 22; 14; 25; 32; 13; 30; 40; 17; 6; 44; 20; 16; 26; 6; 21; 42; 15; 48; 28; 44; 11; 38; 5; 26; 36; 17; 19; 35; 25; 39; 7; 15; 17; 34; 20; 2; 28; 50; 1; 27; 12; 42; 50; 1; 46; 18; 18; 35; 29; 33; 10; 13; 21; 26; 5; 31; 10; 4; 47; 27; 2; 41; 49; 4; 12; 18; 16; 0; 47; 0; 49; 46; 9; 11; 42; 1; 5; 8; 33; 40; 47; 42; 17; 5; 7; 29; 44; 0; 34; 50; 35; 48; 43; 26; 18; 7; 11; 45; 22; 9; 34; 26; 45; 10; 11; 9; 1; 21; 41; 26; 20; 35; 39; 32; 2; 46; 41; 32; 15; 47; 48; 29; 30; 38; 43; 15; 19; 14; 11; 12; 11; 42; 35; 13; 32; 23; 44; 30; 6; 1; 47; 9; 3; 36; 21; 37; 42; 16; 11; 13; 22; 39; 11; 32; 13; 9; 28; 17; 2; 43; 46; 41; 47; 48; 45; 43; 22; 45; 19; 28; 29; 34; 49; 44; 9; 32; 45; 49; 44; 11; 41; 27; 0; 18; 9; 36; 34; 50; 48; 49; 10; 10; 41; 28; 35; 34; 25; 1; 20; 40; 38; 21; 6; 39; 2; 7; 39; 5; 13; 29; 6; 39; 46; 43; 45; 44; 18; 42; 3; 22; 7; 17; 45; 48; 4; 10; 43; 7; 35; 41; 29; 39; 3; 7; 32; 42; 42; 8; 16; 3; 13; 21; 35; 36; 43; 10; 28; 40; 0; 0; 36; 42; 6; 36; 34; 32; 36; 44; 8; 8; 34; 2; 31; 1; 5; 14; 7; 46; 1; 36; 21; 36; 46; 15; 46; 6; 38; 50; 5; 12; 47; 29; 1; 29; 1; 10; 0; 24; 2; 43; 46; 4; 29; 50; 49; 11; 6; 18; 49; 23; 31; 4; 35; 46; 23; 15; 48; 34; 41; 48; 24; 2; 33; 28; 2; 2; 6; 21; 28; 0; 38; 45; 25; 36; 44; 42; 36; 34; 37; 34; 44; 26; 36; 6; 16; 40; 3; 41; 46; 46; 45; 16; 23; 16; 40; 35; 21; 14; 2; 45; 10; 22; 44; 2; 43; 16; 31; 47; 23; 15; 25; 44; 21; 29; 5; 25; 17; 7; 13; 23; 15; 7; 43; 19; 39; 16; 43; 3; 24; 15; 29; 35; 10; 30; 11; 11; 30; 0; 10; 30; 27; 19; 36; 27; 8; 26; 19; 6; 19; 49; 8; 30; 22; 49; 11; 36; 39; 49; 6; 40; 6; 30; 12; 41; 49; 22; 3; 19; 25; 8; 27; 49; 11; 1; 2; 45; 50; 35; 12; 15; 16; 25; 13; 30; 19; 0; 18; 18; 26; 2; 38; 44; 3; 21; 20; 12; 49; 13; 32; 1; 17; 35; 30; 4; 26; 15; 21; 29; 31; 26; 0; 50; 5; 34; 2; 25; 30; 22; 25; 16; 8; 13; 23; 29; 9; 9; 50; 31; 0; 8; 39; 22; 29; 48; 36; 49; 6; 41; 45; 5; 31; 43; 11; 31; 41; 7; 3; 7; 12; 36; 20; 31; 11; 5; 33; 30; 36; 1; 26; 21; 36; 3; 3; 19; 3; 4; 16; 22; 0; 22; 1; 32; 26; 16; 32; 15; 37; 1; 24; 1; 44; 23; 17; 40; 45; 38; 13; 28; 5; 38; 41; 1; 10; 14; 24; 26; 21; 41; 44; 49; 22; 15; 32; 23; 1; 38; 42; 29; 23; 44; 5; 6; 28; 23; 9; 42; 47; 46; 31; 5; 33; 17; 8; 10; 37; 26; 37; 32; 7; 24; 40; 39; 13; 20; 12; 41; 8; 19; 10; 3; 29; 28; 7; 10; 49; 37; 45; 44; 48; 38; 27; 3; 26; 24; 46; 2; 33; 38; 32; 44; 26; 39; 17; 47; 28; 3; 45; 27; 36; 8; 14; 20; 8; 39; 40; 20; 9; 11; 38; 14; 39; 34; 20; 22; 39; 29; 48; 19; 17; 18; 45; 14; 32; 40; 14; 4; 33; 27; 45; 31; 4; 27; 21; 43; 9; 1; 7; 40; 12; 14; 30; 2; 19; 22; 42; 5; 12; 10; 7; 2; 24; 24; 41; 10; 3; 39; 7; 47; 35; 31; 8; 32; 28; 25; 15; 42; 3; 37; 32; 35; 50; 25; 18; 10; 45; 8; 34; 15; 3; 29; 18; 46; 19; 48; 12; 14; 31; 30; 9; 0; 49; 14; 42; 15; 12; 20; 32; 18; 9; 41; 26; 17; 1; 24; 16; 46; 30; 14; 14; 14; 47; 17; 0; 0; 17; 39; 4; 13; 32; 35; 15; 8; 35; 13; 2; 37; 29; 22; 27; 21; 32; 9; 24; 23; 3; 29; 33; 1; 13; 14; 1; 20; 41; 49; 29; 23; 11; 2; 17; 24; 15; 15; 21; 44; 4; 28; 12; 2; 23; 17; 22; 6; 12; 8; 35; 19; 1; 15; 5; 47; 33; 11; 19; 8; 0; 10; 46; 46; 38; 36; 7; 0; 8; 2; 2; 43; 31; 49; 1; 4; 30; 25; 49; 15; 9; 29; 10; 21; 0; 29; 39; 18; 28; 48; 20; 8; 7; 8; 2; 3; 8; 7; 14; 41; 18; 7; 46; 12; 49; 41; 41; 26; 39; 43; 34; 32; 9; 11; 5; 25; 34; 20; 1; 21; 25; 39; 49; 28; 42; 41; 9; 29; 11; 18; 20; 31; 3; 33; 7; 43; 48; 2; 29; 14; 40; 13; 8; 4; 40; 11; 12; 27; 25; 5; 39; 40; 10; 20; 34; 46; 50; 40; 26; 34; 50; 35; 2; 47; 0; 8; 44; 0; 37; 27; 10; 19; 50; 24; 37; 1; 35; 5; 23; 0; 1; 12; 30; 30; 17; 19; 9; 17; 10; 4; 49; 44; 33; 34; 44; 10; 28; 34; 18; 46; 41; 5; 16; 49; 11; 16; 2; 31; 39; 32; 12; 35; 18; 35; 7; 12; 18; 3; 21; 13; 37; 14; 26; 8; 11; 42; 5; 32; 5; 48; 46; 17; 4; 44; 44; 32; 41; 29; 40; 5; 14; 30; 1; 17; 32; 41; 49; 50; 16; 10; 33; 39; 1; 26; 14; 40; 46; 23; 42; 9; 45; 38; 2; 41; 22; 12; 45; 13; 28; 50; 19; 40; 30; 8; 49; 11; 12; 13; 31; 3; 44; 42; 32; 2; 19; 29; 13; 7; 35; 23; 49; 23; 48; 32; 25; 36; 14; 24; 15; 20; 48; 11; 11; 15; 38; 0; 25; 3; 32; 2; 43; 41; 14; 17; 32; 20; 40; 16; 11; 17; 1; 3; 20; 38; 6; 11; 10; 13; 7; 19; 39; 40; 34; 15; 40; 1; 49; 37; 47; 0; 26; 28; 4; 33; 17; 21; 2; 20; 31; 15; 18; 27; 18; 28; 17; 6; 9])
19
+
20
+ let test5 _ = assert_equal 0 (beautifulSplits [49; 22; 17; 49; 46; 40; 47; 30; 40; 36; 9; 21; 32; 39; 47; 45; 33; 11; 9; 11; 24; 48; 33; 15; 27; 48; 5; 44; 2; 49; 22; 16; 31; 4; 31; 21; 46; 40; 8; 15; 14; 17; 24; 25; 0; 7; 16; 37; 7; 48; 34; 1; 7; 48; 25; 26; 12; 10; 44; 16; 37; 10; 30; 49; 25; 30; 8; 8; 32; 43; 28; 40; 10; 34; 1; 47; 16; 12; 20; 50; 15; 8; 1; 36; 44; 14; 27; 33; 26; 39; 26; 5; 5; 26; 6; 40; 17; 30; 20; 28; 47; 29; 50; 23; 20; 20; 26; 34; 25; 44; 32; 23; 50; 7; 45; 7; 40; 0; 6; 9; 9; 21; 4; 3; 16; 16; 3; 32; 20; 30; 45; 43; 23; 36; 11; 25; 38; 30; 24; 30; 22; 35; 12; 47; 7; 7; 39; 33; 7; 4; 1; 47; 8; 20; 27; 4; 34; 43; 39; 45; 32; 50; 35; 43; 35; 0; 3; 45; 36; 42; 0; 45; 10; 29; 26; 47; 17; 25; 18; 29; 33; 35; 43; 23; 35; 29; 27; 7; 31; 48; 11; 24; 15; 44; 5; 2; 23; 3; 27; 44; 47; 0; 30; 25; 46; 18; 24; 4; 31; 10; 35; 5; 24; 49; 34; 24; 36; 28; 22; 0; 30; 3; 41; 40; 48; 28; 24; 19; 36; 41; 8; 17; 50; 9; 41; 21; 45; 14; 5; 24; 11; 26; 0; 4; 24; 31; 45; 36; 5; 45; 25; 6; 23; 37; 43; 35; 2; 25; 32; 21; 17; 34; 21; 41; 50; 4; 0; 43; 5; 13; 9; 49; 10; 17; 11; 42; 5; 49; 6; 2; 24; 5; 46; 25; 2; 32; 0; 38; 2; 36; 42; 31; 25; 3; 47; 1; 43; 40; 40; 50; 28; 2; 21; 2; 36; 32; 5; 42; 31; 35; 22; 37; 1; 27; 2; 45; 36; 18; 13; 49; 43; 9; 26; 29; 44; 34; 29; 42; 31; 23; 49; 17; 45; 8; 5; 25; 0; 10; 7; 45; 11; 34; 26; 41; 40; 3; 41; 12; 16; 31; 21; 14; 18; 21; 39; 44; 16; 34; 23; 45; 43; 32; 4; 42; 12; 15; 43; 0; 21; 23; 3; 21; 33; 42; 8; 38; 8; 6; 0; 16; 21; 38; 8; 41; 25; 46; 7; 12; 45; 24; 32; 5; 7; 4; 2; 1; 0; 30; 9; 19; 39; 5; 23; 16; 26; 45; 5; 8; 38; 38; 50; 23; 40; 1; 30; 34; 45; 46; 15; 15; 50; 23; 10; 50; 20; 32; 27; 28; 43; 39; 29; 47; 34; 34; 38; 3; 38; 15; 48; 45; 44; 16; 36; 33; 16; 6; 17; 33; 30; 13; 36; 17; 48; 48; 39; 40; 27; 36; 18; 49; 50; 29; 2; 5; 18; 26; 44; 19; 21; 37; 8; 27; 4; 28; 38; 10; 46; 28; 11; 49; 7; 42; 20; 28; 29; 11; 11; 49; 36; 46; 41; 26; 42; 41; 33; 36; 20; 40; 32; 3; 14; 9; 20; 28; 35; 49; 28; 31; 30; 44; 17; 40; 48; 33; 29; 47; 37; 18; 0; 43; 28; 49; 29; 4; 41; 13; 2; 38; 29; 19; 28; 13; 12; 41; 50; 36; 17; 38; 42; 17; 42; 7; 47; 11; 7; 9; 12; 19; 45; 15; 15; 5; 46; 41; 26; 10; 21; 44; 19; 28; 50; 37; 46; 6; 39; 0; 37; 22; 46; 14; 28; 29; 37; 47; 25; 30; 5; 13; 34; 28; 44; 47; 49; 0; 34; 39; 21; 20; 13; 25; 15; 9; 32; 45; 29; 14; 13; 46; 49; 45; 41; 4; 10; 12; 16; 18; 15; 40; 9; 29; 19; 9; 45; 36; 4; 40; 9; 47; 30; 28; 28; 5; 4; 15; 48; 11; 20; 2; 14; 26; 46; 4; 33; 30; 3; 32; 18; 44; 27; 21; 19; 27; 43; 39; 47; 21; 25; 5; 46; 9; 18; 15; 22; 7; 40; 38; 33; 44; 44; 30; 32; 40; 50; 2; 28; 30; 36; 27; 4; 34; 22; 46; 1; 26; 32; 25; 11; 11; 45; 7; 49; 38; 50; 5; 34; 31; 21; 47; 15; 13; 10; 37; 14; 1; 14; 15; 38; 19; 34; 45; 10; 11; 28; 13; 34; 13; 25; 14; 49; 4; 38; 40; 10; 49; 44; 48; 28; 5; 30; 23; 37; 3; 39; 47; 27; 9; 39; 5; 11; 29; 7; 41; 29; 7; 26; 31; 42; 31; 38; 40; 33; 49; 45; 30; 11; 7; 45; 26; 6; 22; 28; 44; 40; 23; 44; 15; 35; 5; 31; 28; 31; 23; 50; 6; 10; 0; 44; 32; 5; 40; 40; 14; 37; 22; 4; 24; 5; 33; 14; 11; 1; 3; 4; 38; 50; 41; 15; 45; 21; 35; 36; 19; 9; 43; 1; 40; 23; 41; 39; 8; 2; 50; 7; 47; 7; 30; 43; 47; 45; 4; 11; 28; 43; 11; 34; 47; 40; 29; 39; 41; 24; 22; 45; 23; 40; 13; 9; 43; 9; 26; 49; 23; 34; 9; 49; 6; 24; 32; 20; 16; 42; 43; 29; 43; 46; 36; 40; 30; 18; 23; 37; 14; 4; 6; 7; 2; 7; 22; 32; 20; 43; 36; 31; 30; 24; 40; 30; 45; 31; 7; 8; 50; 31; 8; 8; 16; 9; 28; 5; 46; 22; 34; 21; 48; 12; 18; 6; 30; 6; 18; 22; 26; 4; 28; 11; 31; 48; 7; 13; 10; 24; 48; 15; 22; 0; 29; 5; 29; 39; 23; 30; 0; 27; 9; 19; 12; 14; 7; 6; 6; 21; 16; 15; 39; 13; 33; 36; 0; 24; 28; 30; 14; 10; 46; 1; 39; 9; 24; 26; 35; 21; 15; 45; 48; 43; 36; 22; 27; 12; 26; 48; 1; 46; 2; 3; 41; 24; 39; 45; 41; 24; 3; 21; 38; 26; 37; 6; 48; 17; 46; 50; 34; 19; 44; 28; 1; 43; 2; 9; 12; 23; 20; 18; 13; 43; 48; 50; 39; 18; 1; 17; 17; 0; 1; 21; 25; 19; 23; 40; 35; 50; 2; 45; 42; 26; 12; 12; 12; 7; 27; 45; 18; 1; 6; 4; 48; 40; 3; 32; 3; 13; 48; 17; 23; 30; 41; 1; 39; 33; 15; 16; 43; 21; 13; 18; 8; 49; 27; 30; 0; 43; 20; 27; 50; 39; 1; 44; 34; 39; 15; 7; 22; 14; 24; 22; 45; 20; 33; 2; 50; 30; 6; 17; 43; 5; 26; 29; 3; 13; 45; 46; 1; 16; 11; 3; 23; 29; 45; 13; 30; 15; 18; 27; 31; 9; 46; 44; 15; 23; 13; 47; 7; 25; 17; 33; 27; 4; 8; 37; 33; 19; 26; 46; 27; 2; 23; 49; 15; 11; 20; 48; 10; 47; 47; 11; 49; 4; 11; 20; 23; 47; 50; 6; 9; 26; 11; 38; 32; 25; 27; 36; 28; 12; 47; 43; 36; 24; 17; 15; 31; 44; 49; 48; 31; 46; 2; 48; 15; 16; 22; 24; 41; 42; 45; 26; 6; 38; 6; 17; 43; 9; 4; 47; 32; 19; 22; 5; 29; 35; 35; 19; 10; 15; 45; 3; 32; 42; 20; 39; 8; 1; 16; 39; 7; 17; 34; 24; 4; 36; 42; 5; 47; 30; 4; 46; 24; 28; 48; 41; 3; 24; 4; 34; 35; 20; 30; 40; 9; 38; 32; 22; 49; 29; 39; 3; 35; 31; 23; 46; 45; 32; 43; 50; 37; 8; 1; 36; 18; 6; 12; 28; 10; 20; 2; 3; 15; 26; 30; 25; 37; 42; 40; 13; 1; 49; 35; 1; 1; 18; 35; 33; 37; 6; 3; 21; 33; 29; 30; 2; 22; 40; 8; 39; 18; 5; 15; 11; 7; 11; 39; 48; 29; 10; 24; 2; 36; 43; 40; 40; 11; 34; 33; 4; 30; 38; 0; 34; 36; 9; 38; 12; 41; 31; 48; 24; 35; 43; 49; 39; 9; 28; 8; 33; 50; 30; 46; 8; 9; 48; 35; 33; 6; 40; 11; 32; 6; 15; 34; 26; 0; 4; 27; 46; 21; 46; 12; 22; 3; 7; 22; 50; 18; 3; 10; 41; 50; 43; 14; 43; 27; 7; 21; 36; 15; 27; 31; 43; 47; 20; 27; 40; 29; 21; 43; 35; 50; 42; 2; 33; 39; 29; 10; 12; 28; 41; 3; 48; 32; 35; 44; 37; 1; 35; 47; 49; 0; 34; 23; 26; 18; 31; 27; 16; 47; 25; 24; 25; 4; 14; 16; 38; 17; 29; 33; 24; 28; 13; 26; 14; 38; 33; 3; 28; 12; 14; 35; 10; 19; 2; 45; 13; 49; 5; 34; 37; 41; 21; 21; 14; 5; 42; 46; 37; 43; 17; 35; 21; 7; 11; 2; 23; 21; 5; 24; 46; 28; 0; 7; 43; 3; 49; 10; 5; 4; 36; 39; 11; 38; 28; 45; 33; 3; 0; 24; 18; 22; 33; 20; 32; 10; 0; 25; 0; 16; 22; 26; 50; 29; 7; 34; 48; 20; 36; 11; 2; 50; 42; 29; 49; 11; 1; 45; 13; 4; 13; 0; 38; 42; 32; 36; 41; 33; 48; 40; 27; 23; 21; 6; 41; 46; 49; 11; 21; 5; 41; 45; 5; 33; 25; 32; 35; 26; 32; 34; 3; 6; 5; 39; 29; 11; 35; 2; 34; 25; 0; 2; 2; 9; 40; 16; 3; 37; 37; 46; 48; 30; 30; 39; 15; 24; 34; 3; 41; 36; 43; 10; 25; 18; 34; 2; 8; 48; 37; 45; 25; 0; 43; 12; 10; 2; 12; 47; 7; 17; 2; 8; 12; 41; 8; 5; 45; 11; 0; 41; 7; 14; 31; 38; 19; 13; 20; 7; 6; 29; 26; 41; 7; 10; 40; 16; 33; 16; 26; 29; 48; 41; 43; 2; 7; 45; 24; 49; 30; 33; 29; 45; 48; 12; 6; 22; 41; 45; 38; 7; 6; 41; 13; 32; 29; 49; 38; 2; 32; 5; 43; 11; 30; 26; 11; 23; 44; 15; 27; 42; 38; 8; 15; 47; 6; 3; 21; 38; 38; 2; 30; 27; 47; 30; 25; 37; 33; 2; 13; 40; 43; 26; 29; 28; 50; 25; 31; 22; 14; 22; 29; 38; 45; 49; 6; 14; 38; 5; 12; 27; 48; 13; 14; 9; 1; 41; 18; 15; 37; 45; 18; 6; 34; 50; 17; 3; 6; 40; 9; 48; 6; 40; 50; 19; 7; 7; 17; 17; 0; 11; 14; 10; 50; 45; 24; 37; 22; 19; 47; 33; 50; 39; 32; 29; 17; 1; 27; 8; 32; 4; 17; 11; 33; 1; 35; 16; 43; 49; 12; 50; 46; 7; 47; 11; 4; 17; 4; 47; 4; 16; 17; 4; 19; 34; 23; 28; 30; 3; 36; 47; 44; 44; 31; 29; 43; 7; 5; 45; 13; 22; 5; 31; 12; 24; 4; 14; 50; 26; 41; 16; 43; 40; 0; 17; 0; 28; 27; 40; 1; 39; 24; 15; 29; 32; 21; 4; 41; 6; 23; 10; 35; 11; 16; 36; 43; 0; 16; 29; 37; 28; 26; 36; 25; 2; 16; 31; 41; 30; 42; 12; 8; 28; 35; 44; 43; 44; 14; 36; 31; 29; 0; 21; 25; 34; 22; 22; 2; 49; 4; 13; 19; 3; 22; 20; 38; 11; 44; 41; 39; 24; 31; 18; 12; 25; 8; 37; 23; 22; 44; 26; 37; 12; 36; 18; 9; 0; 21; 26; 21; 50; 5; 7; 46; 13; 21; 48; 18; 47; 6; 29; 39; 26; 26; 22; 24; 50; 37; 11; 17; 37; 21; 17; 42; 27; 10; 42; 1; 49; 33; 35; 22; 17; 33; 14; 16; 22; 19; 40; 20; 44; 0; 38; 6; 31; 23; 32; 40; 8; 13; 8; 44; 44; 1; 44; 35; 25; 4; 25; 11; 27; 11; 23; 6; 44; 45; 17; 25; 27; 24; 16; 41; 16; 13; 6; 20; 28; 25; 25; 12; 48; 40; 14; 45; 17; 26; 41; 5; 47; 41; 32; 44; 22; 0; 32; 38; 48; 42; 8; 26; 47; 48; 1; 36; 36; 25; 38; 29; 21; 40; 19; 18; 2; 0; 11; 21; 25; 22; 24; 5; 45; 24; 34; 48; 44; 12; 7; 38; 2; 18; 17; 25; 4; 33; 8; 37; 49; 44; 0; 4; 2; 18; 32; 10; 23; 35; 3; 41; 9; 15; 24; 15; 47; 29; 35; 24; 28; 7; 34; 31; 24; 46; 45; 27; 19; 17; 32; 25; 47; 31; 33; 33; 29; 49; 26; 12; 41; 45; 50; 45; 42; 2; 28; 7; 4; 14; 2; 10; 49; 3; 37; 35; 4; 17; 42; 31; 41; 33; 37; 38; 15; 33; 15; 4; 47; 16; 31; 42; 45; 38; 32; 1; 20; 10; 17; 40; 18; 45; 31; 40; 15; 8; 25; 21; 20; 39; 32; 5; 4; 34; 22; 29; 44; 6; 32; 32; 8; 50; 6; 39; 50; 43; 22; 11; 39; 32; 27; 12; 24; 19; 20; 0; 12; 4; 35; 8; 27; 20; 2; 48; 40; 15; 36; 3; 26; 23; 32; 6; 35; 40; 4; 24; 41; 34; 19; 39; 42; 7; 0; 23; 32; 43; 37; 5; 28; 24; 35; 32; 37; 1; 9; 25; 12; 21; 18; 17; 25; 42; 48; 37; 39; 40; 14; 30; 47; 26; 42; 27; 8; 50; 38; 33; 32; 33; 43; 28; 33; 6; 29; 6; 49; 2; 18; 23; 2; 41; 47; 3; 49; 19; 26; 23; 46; 50; 4; 39; 23; 21; 31; 28; 18; 3; 46; 5; 32; 23; 17; 30; 31; 32; 18; 49; 20; 47; 20; 31; 28; 39; 50; 50; 42; 24; 32; 37; 43; 6; 15; 20; 29; 27; 16; 50; 40; 36; 24; 12; 40; 39; 50; 3; 16; 37; 31; 38; 19; 43; 10; 7; 50; 5; 21; 3; 15; 17; 12; 2; 46; 21; 4; 42; 38; 20; 38; 42; 49; 48; 9; 45; 19; 9; 38; 47; 21; 37; 46; 5; 6; 45; 45; 20; 19; 43; 28; 25; 43; 0; 34; 39; 6; 16; 28; 17; 9; 6; 34; 22; 5; 10; 42; 44; 16; 28; 5; 27; 5; 18; 23; 2; 31; 17; 45; 7; 48; 23; 27; 33; 16; 22; 6; 17; 17; 31; 45; 28; 41; 24; 20; 26; 18; 33; 10; 15; 26; 13; 8; 8; 11; 20; 46; 47; 34; 35; 5; 44; 2; 32; 20; 26; 33; 10; 0; 31; 12; 11; 50; 49; 7; 14; 39; 32; 5; 1; 46; 16; 2; 36; 0; 7; 47; 7; 20; 32; 31; 33; 41; 10; 32; 36; 22; 11; 48; 31; 42; 1; 20; 22; 9; 25; 20; 9; 43; 6; 39; 10; 42; 46; 19; 6; 27; 26; 32; 50; 10; 4; 24; 28; 16; 0; 15; 30; 30; 29; 14; 17; 9; 8; 31; 37; 20; 11; 34; 4; 3; 7; 35; 32; 40; 22; 14; 4; 6; 2; 21; 12; 10; 47; 8; 8; 46; 20; 37; 25; 39; 46; 10; 4; 7; 30; 44; 5; 11; 8; 33; 25; 28; 44; 27; 49; 23; 33; 18; 9; 22; 11; 37; 39; 37; 32; 47; 30; 0; 45; 17; 19; 39; 14; 15; 20; 9; 17; 9; 13; 1; 38; 49; 37; 44; 18; 6; 20; 1; 33; 23; 18; 24; 21; 30; 47; 45; 12; 6; 7; 45; 41; 4; 13; 29; 28; 36; 9; 46; 4; 25; 13; 13; 28; 8; 44; 47; 38; 12; 4; 46; 31; 38; 18; 19; 36; 23; 6; 43; 41; 34; 35; 29; 10; 41; 15; 13; 23; 24; 27; 29; 15; 4; 50; 3; 22; 45; 25; 20; 6; 14; 24; 50; 43; 23; 35; 46; 19; 14; 37; 12; 30; 42; 8; 49; 3; 33; 18; 29; 48; 2; 5; 39; 42; 48; 41; 5; 46; 32; 35; 15; 21; 39; 12; 49; 27; 44; 6; 8; 23; 2; 10; 42; 48; 2; 7; 24; 15; 32; 37; 33; 39; 32; 27; 39; 19; 21; 23; 39; 12; 26; 9; 4; 44; 25; 23; 7; 33; 3; 30; 45; 11; 17; 19; 16; 32; 30; 10; 31; 42; 18; 42; 28; 44; 33; 14; 33; 50; 32; 16; 18; 42; 32; 6; 6; 42; 34; 25; 32; 44; 9; 3; 28; 13; 25; 11; 50; 19; 47; 11; 24; 40; 20; 39; 28; 24; 35; 8; 24; 4; 48; 50; 22; 8; 47; 17; 34; 29; 11; 6; 34; 34; 27; 0; 38; 1; 7; 26; 13; 41; 45; 6; 10; 5; 5; 30; 46; 9; 50; 32; 27; 30; 3; 41; 13; 15; 2; 35; 5; 13; 26; 6; 6; 37; 16; 32; 37; 20; 36; 9; 41; 49; 32; 44; 3; 26; 24; 38; 1; 20; 22; 20; 20; 3; 12; 0; 39; 21; 50; 29; 14; 48; 7; 8; 40; 20; 19; 34; 10; 48; 40; 50; 1; 1; 47; 28; 34; 35; 34; 18; 36; 3; 9; 38; 36; 13; 17; 14; 17; 36; 10; 43; 22; 10; 32; 44; 6; 30; 5; 10; 1; 8; 15; 19; 30; 41; 5; 6; 45; 20; 50; 10; 14; 29; 22; 20; 29; 26; 42; 14; 1; 27; 15; 28; 23; 14; 26; 27; 36; 10; 49; 12; 29; 42; 47; 47; 21; 18; 41; 27; 12; 33; 43; 2; 27; 25; 3; 29; 36; 11; 9; 25; 26; 48; 43; 41; 31; 23; 39; 4; 42; 36; 0; 24; 33; 27; 37; 19; 0; 22; 31; 32; 42; 5; 39; 32; 18; 15; 21; 41; 44; 35; 16; 26; 33; 11; 11; 42; 38; 14; 2; 5; 1; 48; 9; 50; 38; 16; 24; 16; 18; 32; 15; 22; 13; 18; 33; 22; 12; 35; 49; 20; 37; 27; 16; 41; 27; 39; 7; 22; 37; 36; 23; 9; 37; 25; 9; 32; 15; 47; 46; 43; 7; 39; 25; 1; 35; 1; 34; 2; 49; 16; 29; 7; 20; 35; 20; 50; 22; 13; 46; 49; 46; 30; 5; 49; 3; 23; 10; 4; 28; 49; 0; 18; 27; 42; 18; 22; 19; 13; 39; 45; 43; 10; 20; 10; 5; 33; 37; 10; 34; 44; 5; 38; 2; 32; 33; 31; 50; 43; 42; 45; 48; 9; 28; 5; 33; 31; 2; 17; 2; 38; 9; 34; 19; 18; 7; 11; 50; 31; 6; 19; 2; 28; 49; 13; 4; 11; 16; 25; 0; 5; 7; 12; 5; 34; 26; 34; 35; 13; 20; 24; 16; 31; 43; 25; 23; 38; 3; 14; 20; 28; 22; 48; 12; 39; 50; 42; 33; 14; 6; 4; 16; 22; 5; 15; 22; 13; 49; 31; 14; 23; 18; 36; 36; 46; 18; 5; 33; 2; 16; 10; 35; 8; 35; 36; 14; 27; 35; 36; 47; 17; 17; 40; 24; 47; 40; 49; 27; 3; 49; 8; 35; 39; 12; 22; 19; 44; 26; 31; 14; 24; 15; 50; 47; 9; 6; 33; 39; 6; 43; 13; 9; 18; 25; 35; 19; 13; 49; 15; 2; 20; 41; 45; 24; 8; 17; 6; 26; 27; 4; 47; 32; 47; 10; 1; 2; 2; 26; 17; 42; 43; 38; 15; 45; 39; 20; 46; 29; 7; 0; 46; 37; 18; 7; 32; 35; 20; 30; 27; 26; 25; 34; 3; 28; 20; 24; 42; 4; 26; 28; 40; 0; 47; 43; 19; 12; 48; 6; 18; 11; 37; 50; 18; 33; 15; 42; 10; 9; 18; 16; 12; 29; 7; 19; 12; 42; 9; 16; 22; 10; 5; 36; 24; 1; 39; 19; 12; 0; 36; 41; 28; 32; 34; 17; 8; 40; 48; 31; 40; 10; 35; 21; 43; 46; 22; 0; 32; 13; 40; 28; 22; 23; 20; 25; 29; 13; 26; 4; 28; 47; 17; 10; 26; 37; 11; 31; 18; 35; 31; 29; 45; 45; 30; 3; 30; 8; 13; 42; 47; 7; 20; 31; 11; 1; 29; 46; 29; 29; 42; 2; 31; 10; 2; 22; 48; 3; 15; 47; 2; 26; 49; 31; 39; 42; 30; 14; 47; 49; 3; 47; 26; 7; 19; 36; 37; 10; 24; 23; 13; 15; 45; 6; 50; 11; 35; 40; 0; 18; 38; 34; 45; 34; 9; 39; 22; 7; 45; 12; 15; 27; 34; 25; 50; 25; 11; 38; 17; 3; 8; 43; 43; 46; 38; 31; 24; 34; 30; 10; 14; 16; 13; 47; 3; 16; 11; 20; 30; 16; 10; 16; 0; 36; 48; 12; 22; 12; 31; 11; 26; 17; 6; 38; 34; 11; 6; 40; 38; 28; 43; 45; 37; 18; 4; 32; 28; 25; 6; 43; 29; 8; 43; 3; 19; 21; 20; 0; 18; 33; 24; 35; 28; 11; 15; 12; 6; 50; 3; 12; 2; 7; 24; 17; 15; 14; 30; 5; 40; 20; 6; 39; 23; 47; 1; 48; 46; 1; 17; 39; 6; 24; 47; 50; 2; 19; 28; 27; 37; 19; 22; 7; 18; 27; 34; 48; 23; 28; 28; 15; 2; 2; 23; 38; 44; 11; 29; 31; 6; 21; 24; 1; 1; 14; 48; 41; 24; 38; 11; 31; 32; 25; 11; 10; 42; 9; 46; 27; 30; 24; 19; 34; 12; 30; 36; 7; 6; 35; 10; 12; 39; 42; 27; 6; 42; 12; 40; 17; 42; 49; 19; 44; 2; 25; 41; 23; 48; 31; 42; 45; 27; 9; 20; 45; 47; 18; 19; 48; 50; 41; 13; 18; 10; 25; 42; 21; 25; 8; 19; 37; 49; 12; 24; 28; 9; 17; 40; 40; 23; 34; 11; 8; 20; 38; 40; 34; 5; 37; 28; 49; 15; 50; 34; 38; 25; 37; 12; 28; 1; 29; 19; 0; 16; 0; 3; 37; 21; 19; 49; 4; 46; 25; 35; 45; 43; 12; 24; 2; 4; 9; 15; 25; 25; 25; 1; 38; 12; 38; 46; 33; 40; 36; 39; 9; 48; 29; 50; 4; 21; 31; 26; 7; 29; 40; 33; 35; 38; 33; 31; 33; 23; 40; 2; 2; 43; 48; 34; 20; 38; 34; 43; 34; 45; 1; 11; 11; 48; 17; 26; 17; 42; 43; 2; 33; 23; 36; 31; 1; 8; 11; 36; 48; 25; 13; 9; 39; 3; 23; 46; 46; 1; 17; 40; 34; 41; 22; 3; 8; 19; 25; 16; 5; 24; 33; 1; 34; 7; 8; 26; 15; 30; 7; 3; 9; 41; 37; 9; 12; 18; 0; 43; 22; 50; 19; 1; 35; 34; 18; 27; 47; 19; 37; 43; 13; 12; 41; 25; 26; 6; 2; 23; 4; 24; 44; 16; 13; 7; 11; 5; 50; 5; 18; 34; 4; 32; 16; 25; 42; 30; 23; 17; 11; 45; 33; 8; 12; 18; 28; 15; 16; 25; 37; 6; 21; 25; 3; 37; 39; 39; 9; 44; 35; 44; 37; 11; 20; 35; 19; 33; 1; 25; 36; 45; 12; 12; 22; 13; 13; 6; 38; 21; 44; 38; 36; 20; 33; 16; 6; 22; 10; 20; 10; 39; 47; 40; 18; 5; 23; 4; 49; 19; 24; 48; 43; 41; 43; 42; 13; 38; 26; 13; 20; 49; 31; 11; 21; 10; 38; 12; 12; 30; 12; 12; 17; 5; 7; 4; 1; 16; 6; 8; 12; 46; 47; 8; 47; 28; 39; 28; 36; 47; 28; 17; 12; 38; 8; 41; 43; 18; 45; 22; 8; 47; 31; 44; 32; 14; 37; 43; 44; 24; 16; 19; 19; 46; 15; 40; 28; 0; 40; 36; 25; 47; 35; 15; 12; 46; 38; 16; 16; 35; 0; 39; 0; 1; 47; 43; 33; 3; 11; 44; 22; 9; 36; 42; 27; 16; 28; 43; 25; 31; 14; 47; 13; 16; 36; 8; 41; 30; 24; 10; 33; 45; 24; 4; 19; 36; 45; 47; 30; 28; 36; 45; 44; 5; 30; 4; 12; 42; 10; 0; 29; 20; 11; 50; 23; 4; 17; 23; 24; 2; 32; 48; 15; 36; 14; 5; 47; 31; 33; 36; 17; 20; 21; 21; 40; 34; 20; 50; 49; 24; 23; 18; 19; 8; 11; 37; 24; 15; 44; 2; 35; 17; 35; 5; 34; 3; 46; 13; 36; 17; 9; 21; 18; 13; 4; 38; 45; 23; 28; 15; 0; 35; 15; 49; 10; 4; 34; 33; 45; 5; 28; 35; 0; 32; 24; 36; 3; 6; 45; 41; 4; 15; 22; 24; 50; 48; 3; 10; 35; 45; 14; 14; 11; 8; 5; 4; 41; 16; 0; 36; 18; 34; 23; 24; 2; 9; 33; 17; 4; 12; 16; 36; 45; 8; 23; 15; 44; 50; 39; 36; 26; 42; 11; 26; 29; 0; 45; 26; 35; 41; 39; 3; 10; 6; 41; 27; 0; 27; 12; 4; 27; 11; 49; 38; 19; 21; 39; 27; 8; 26; 48; 3; 22; 42; 46; 13; 48; 2; 36; 2; 45; 10; 45; 24; 43; 29; 21; 2; 2; 9; 8; 12; 3; 29; 16; 16; 44; 19; 48; 36; 17; 39; 22; 44; 49; 13; 41; 43; 28; 26; 1; 39; 21; 4; 41; 29; 22; 36; 19; 25; 35; 19; 49; 44; 36; 35; 5; 14; 48; 40; 5; 28; 41; 37; 9; 42; 6; 39; 44; 10; 0; 5; 16; 18; 28; 40; 30; 4; 32; 31; 18; 43; 28; 34; 25; 18; 16; 40; 30; 0; 28; 43; 12; 43; 48; 32; 9; 31; 33; 12; 29; 18; 23; 7; 44; 36; 6; 47; 16; 10; 38; 17; 9; 11; 23; 23; 29; 44; 10; 39; 19; 48; 7; 50; 10; 2; 10; 11; 22; 1; 19; 17; 45; 24; 1; 49; 14; 40; 39; 42; 21; 14; 45; 22; 47; 49; 4; 34; 32; 39; 7; 27; 4; 16; 34; 27; 8; 49; 41; 22; 33; 28; 50; 45; 16; 47; 36; 46; 14; 25; 6; 9; 19; 5; 39; 2; 49; 29; 42; 28; 49; 29; 7; 25; 23; 33; 38; 38; 15; 50; 1; 1; 13; 9; 39; 13; 16; 8; 24; 1; 14; 35; 25; 50; 24; 35; 40; 29; 11; 14; 49; 45; 37; 48; 27; 22; 28; 30; 32; 5; 26; 42; 33; 24; 3; 6; 22; 5; 44; 0; 6; 28; 48; 43; 38; 5; 11; 30; 2; 10; 28; 3; 48; 11; 10; 16; 12; 24; 8; 28; 46; 34; 49; 16; 4; 3; 2; 34; 8; 31; 10; 22; 29; 34; 35; 25; 47; 16; 4; 13; 4; 41; 18; 49; 34; 23; 21; 23; 45; 13; 30; 3; 35; 45; 3; 41; 23; 24; 14; 44; 31; 30; 50; 10; 29; 16; 12; 9; 6; 9; 2; 9; 6; 29; 42; 38; 5; 20; 15; 13; 2; 23; 0; 10; 3; 39; 16; 44; 14; 34; 0; 15; 33; 11; 50; 9; 11; 31; 9; 3; 29; 1; 18; 48; 37; 10; 15; 25; 49; 34; 33; 0; 50; 39; 32; 23; 19; 33; 2; 30; 1; 37; 21; 41; 31; 46; 17; 27; 46; 39; 44; 5; 11; 3; 22; 34; 24; 9; 23; 25; 21; 31; 29; 3; 42; 28; 22; 27; 46; 35; 10; 32; 25; 36; 21; 16; 24; 32; 32; 15; 36; 42; 14; 7; 39; 11; 33; 39; 36; 2; 36; 34; 14; 29; 8; 2; 35; 23; 34; 26; 41; 22; 17; 34; 47; 19; 28; 41; 46; 29; 25; 24; 33; 37; 2; 42; 3; 23; 1; 22; 17; 12; 14; 10; 13; 40; 2; 1; 48; 23; 24; 44; 42; 34; 22; 3; 29; 27; 40; 43; 36; 35; 35; 26; 44; 22; 16; 27; 30; 21; 34; 31; 0; 21; 42; 44; 10; 10; 29; 50; 34; 33; 41; 14; 33; 36; 32; 39; 13; 23; 20; 18; 5; 43; 14; 14; 27; 43; 34; 0; 26; 14; 24; 2; 12; 29; 28; 48; 3; 23; 47; 27; 0; 29; 39; 31; 26; 48; 29; 41; 40; 24; 50; 43; 20; 12; 8; 42; 22; 19; 8; 40; 44; 44; 20; 22; 44; 3; 33; 36; 17; 1; 2; 39; 7; 37; 16; 4; 41; 5; 42; 7; 30; 25; 2; 45; 41; 33; 9; 50; 25; 14; 50; 5; 15; 46; 40; 39; 0; 40; 45; 39; 11; 47; 41; 35; 15; 0; 11; 3; 26; 21; 19; 35; 21; 13; 1; 18; 26; 22; 15; 19; 2; 38; 32; 13; 30; 8; 24; 42; 13; 22; 27; 49; 43; 4; 32; 31; 21; 23; 13; 8; 14; 28; 19; 1; 6; 33; 21; 33; 14; 50; 0; 32; 34; 32; 36; 46; 30; 43; 24; 18; 3; 31; 24; 46; 2; 28; 11; 48; 22; 20; 5; 11; 19; 12; 1; 19; 22; 40; 1; 21; 4; 36; 39; 43; 18; 32; 47; 32; 40; 6; 12; 11; 44; 30; 1; 22; 5; 45; 27; 36; 30; 6; 7; 41; 42; 36; 27; 31; 2; 44; 38; 4; 49; 37; 36; 40; 22; 23; 5; 16; 39; 42; 20; 23; 20; 50; 0; 7; 39; 36; 25; 46; 49; 12; 8; 15; 27; 50; 19; 9; 12; 22; 47; 9; 15; 22; 34; 22; 26; 26; 28; 34; 6; 18; 49; 12; 3; 31; 36; 40; 10; 47; 23; 36; 35; 21; 4; 3; 13; 43; 11; 50; 44; 4; 13; 31; 45; 50; 43; 24; 48; 44; 5; 1; 9; 21; 35; 15; 30; 28; 29; 25; 13; 47; 49; 48; 0; 45; 25; 45; 25; 8; 38; 27; 35; 50; 38; 21; 28; 48; 28; 15; 50; 0; 5; 13; 0; 12; 39; 36; 37; 18; 25; 32; 16; 33; 17; 24; 31; 0; 2; 43; 33; 30; 9; 2; 50; 30; 33; 24; 0; 12; 20; 29; 8; 41; 3; 10; 23; 13; 28; 22; 3; 41; 43; 7; 19; 41; 0; 36; 18; 45; 23; 36; 22; 42; 50; 49; 18; 33; 41; 14; 20; 16])
21
+
22
+ let test6 _ = assert_equal 0 (beautifulSplits [18; 15; 10; 6; 2; 27; 15; 27; 18; 31; 48; 2; 42; 35; 9; 46; 24; 8; 16; 50; 29; 39; 8; 11; 11; 37; 27; 36; 20; 10; 22; 40; 22; 49; 12; 49; 46; 0; 42; 2; 46; 4; 16; 4; 19; 37; 36; 4; 25; 12; 38; 42; 15; 42; 34; 27; 18; 15; 10; 25; 33; 20; 50; 39; 21; 5; 26; 28; 1; 32; 49; 5; 27; 37; 18; 40; 47; 9; 24; 43; 48; 48; 10; 4; 25; 0; 33; 45; 45; 36; 36; 27; 20; 10; 26; 34; 3; 47; 2; 4; 19; 25; 9; 45; 40; 43; 22; 2; 13; 8; 25; 44; 5; 5; 43; 31; 26; 0; 50; 18; 1; 1; 41; 50; 4; 44; 0; 19; 32; 26; 19; 50; 16; 11; 49; 37; 27; 7; 48; 40; 19; 48; 5; 1; 37; 19; 35; 7; 45; 5; 19; 50; 39; 32; 35; 44; 48; 9; 6; 33; 40; 31; 3; 0; 17; 37; 26; 16; 29; 2; 7; 26; 48; 5; 25; 5; 28; 50; 38; 28; 10; 50; 45; 28; 22; 13; 38; 29; 32; 29; 29; 33; 8; 31; 5; 29; 39; 33; 3; 17; 22; 16; 34; 30; 40; 44; 50; 4; 41; 9; 41; 38; 39; 50; 10; 17; 14; 50; 47; 30; 41; 40; 1; 32; 1; 37; 28; 37; 8; 16; 5; 12; 0; 0; 32; 27; 43; 44; 42; 9; 31; 9; 8; 12; 46; 34; 37; 32; 34; 47; 24; 26; 16; 22; 43; 14; 4; 13; 13; 7; 33; 34; 21; 22; 12; 7; 30; 19; 25; 23; 2; 39; 48; 9; 42; 12; 33; 3; 16; 33; 39; 1; 43; 12; 16; 18; 40; 34; 50; 6; 17; 37; 38; 18; 35; 46; 34; 24; 40; 1; 44; 20; 29; 45; 46; 33; 12; 44; 4; 31; 18; 38; 21; 24; 9; 44; 39; 18; 4; 34; 18; 40; 28; 15; 47; 32; 43; 43; 15; 35; 27; 49; 16; 23; 15; 40; 16; 35; 2; 18; 44; 46; 42; 41; 11; 24; 28; 26; 6; 26; 27; 35; 18; 18; 39; 30; 5; 6; 27; 6; 24; 9; 35; 20; 2; 3; 4; 14; 34; 38; 40; 24; 36; 7; 23; 18; 20; 49; 33; 44; 0; 47; 1; 7; 8; 14; 31; 34; 23; 42; 11; 21; 38; 43; 41; 2; 24; 32; 18; 49; 39; 46; 5; 6; 11; 3; 45; 18; 6; 36; 40; 29; 36; 3; 41; 2; 34; 28; 36; 50; 23; 10; 41; 45; 40; 33; 40; 33; 6; 5; 1; 47; 38; 20; 24; 50; 30; 5; 14; 12; 46; 42; 45; 28; 39; 13; 25; 2; 28; 40; 25; 25; 9; 45; 11; 45; 27; 40; 5; 3; 34; 20; 30; 32; 8; 31; 49; 34; 14; 25; 9; 32; 16; 6; 26; 32; 30; 2; 29; 34; 44; 18; 37; 31; 0; 1; 15; 40; 5; 0; 38; 14; 4; 15; 39; 25; 40; 32; 16; 5; 2; 10; 2; 20; 35; 11; 47; 41; 11; 6; 23; 15; 36; 50; 36; 29; 16; 48; 16; 27; 1; 33; 35; 42; 17; 21; 28; 34; 27; 36; 44; 18; 29; 17; 43; 19; 27; 34; 43; 7; 11; 2; 25; 40; 24; 39; 1; 46; 2; 32; 4; 8; 15; 37; 32; 11; 13; 8; 18; 32; 12; 50; 7; 24; 33; 6; 12; 32; 15; 14; 42; 9; 49; 24; 19; 21; 13; 43; 33; 18; 32; 32; 6; 38; 49; 37; 6; 34; 24; 49; 10; 43; 13; 8; 50; 44; 10; 4; 39; 1; 41; 8; 44; 23; 4; 39; 42; 15; 41; 5; 35; 15; 30; 18; 31; 22; 41; 30; 3; 25; 0; 8; 34; 36; 8; 3; 46; 42; 46; 43; 38; 11; 19; 21; 5; 21; 43; 32; 2; 38; 49; 13; 27; 36; 28; 46; 2; 37; 49; 26; 8; 43; 48; 43; 10; 22; 23; 25; 29; 22; 7; 45; 17; 35; 39; 20; 50; 26; 2; 6; 37; 48; 10; 8; 35; 13; 38; 5; 10; 40; 35; 21; 41; 3; 8; 42; 47; 45; 24; 48; 48; 47; 47; 27; 23; 2; 13; 29; 2; 43; 17; 41; 11; 38; 37; 41; 42; 18; 15; 12; 40; 23; 20; 27; 12; 49; 45; 47; 0; 3; 48; 28; 2; 32; 14; 42; 34; 34; 23; 35; 24; 14; 20; 24; 40; 14; 22; 11; 1; 19; 38; 0; 9; 28; 47; 18; 28; 17; 3; 22; 9; 49; 14; 5; 4; 0; 16; 49; 3; 12; 7; 34; 24; 34; 50; 11; 33; 29; 11; 35; 8; 5; 1; 41; 42; 0; 37; 3; 42; 10; 15; 24; 44; 39; 41; 35; 10; 21; 34; 20; 38; 21; 26; 25; 42; 16; 12; 10; 41; 3; 42; 5; 29; 2; 44; 9; 22; 41; 11; 27; 3; 22; 37; 16; 41; 28; 16; 17; 43; 44; 14; 25; 38; 25; 22; 17; 40; 50; 4; 44; 2; 21; 36; 28; 9; 44; 22; 39; 36; 46; 33; 43; 1; 16; 21; 35; 27; 34; 34; 46; 45; 10; 48; 32; 35; 5; 4; 30; 20; 23; 38; 8; 39; 1; 35; 38; 18; 3; 11; 42; 50; 19; 10; 26; 22; 41; 48; 9; 26; 7; 28; 29; 9; 41; 6; 3; 49; 0; 33; 20; 45; 46; 49; 48; 45; 5; 16; 2; 44; 24; 36; 38; 41; 11; 32; 11; 49; 44; 5; 22; 17; 31; 12; 23; 20; 6; 23; 7; 29; 7; 5; 25; 49; 41; 42; 3; 49; 38; 25; 42; 48; 11; 49; 11; 2; 34; 39; 7; 6; 47; 44; 35; 19; 47; 26; 21; 13; 19; 26; 0; 16; 9; 5; 25; 27; 23; 4; 29; 30; 29; 40; 42; 45; 42; 37; 0; 0; 32; 5; 7; 23; 30; 20; 36; 46; 30; 32; 34; 33; 45; 18; 38; 45; 29; 31; 28; 15; 1; 20; 27; 27; 1; 48; 50; 31; 26; 12; 18; 41; 11; 27; 15; 18; 8; 6; 45; 41; 0; 17; 25; 9; 43; 42; 9; 4; 18; 35; 50; 12; 29; 35; 14; 41; 25; 25; 33; 27; 22; 34; 13; 44; 38; 46; 36; 47; 12; 20; 2; 29; 43; 46; 39; 19; 24; 20; 25; 48; 2; 12; 25; 8; 13; 17; 10; 31; 49; 7; 39; 12; 31; 29; 1; 19; 36; 0; 43; 38; 19; 4; 33; 3; 4; 21; 45; 45; 18; 27; 22; 7; 23; 40; 35; 25; 41; 32; 41; 29; 3; 12; 29; 22; 43; 11; 30; 31; 20; 24; 21; 41; 36; 48; 16; 14; 39; 13; 10; 23; 17; 44; 50; 1; 16; 2; 12; 15; 8; 8; 49; 23; 2; 50; 50; 49; 32; 48; 18; 39; 15; 7; 37; 11; 24; 2; 47; 18; 36; 25; 33; 15; 23; 11; 8; 45; 49; 43; 23; 48; 21; 36; 20; 30; 40; 50; 50; 0; 20; 20; 20; 32; 37; 34; 32; 47; 13; 28; 3; 41; 24; 45; 8; 25; 19; 2; 21; 30; 6; 42; 50; 40; 46; 8; 31; 28; 25; 40; 0; 23; 34; 15; 46; 4; 25; 17; 23; 37; 4; 15; 0; 1; 42; 29; 24; 32; 32; 15; 48; 49; 7; 3; 30; 36; 39; 41; 45; 13; 32; 2; 23; 19; 39; 22; 43; 36; 1; 27; 32; 6; 19; 24; 49; 31; 17; 39; 27; 30; 2; 39; 42; 42; 7; 26; 12; 22; 15; 32; 15; 14; 32; 15; 25; 1; 45; 16; 45; 33; 47; 13; 39; 32; 35; 13; 5; 31; 34; 14; 4; 6; 15; 43; 24; 50; 23; 28; 14; 1; 48; 40; 35; 42; 16; 36; 22; 43; 0; 29; 7; 5; 0; 7; 50; 28; 31; 37; 14; 18; 9; 17; 17; 47; 19; 45; 33; 47; 36; 15; 2; 30; 28; 50; 26; 3; 27; 12; 29; 29; 7; 38; 49; 7; 9; 11; 15; 41; 38; 38; 34; 36; 17; 41; 15; 46; 1; 44; 10; 48; 28; 45; 32; 19; 14; 7; 28; 2; 26; 41; 7; 10; 24; 0; 50; 3; 17; 47; 37; 14; 20; 39; 48; 8; 34; 47; 14; 14; 40; 23; 23; 46; 1; 18; 48; 15; 39; 0; 21; 38; 32; 3; 38; 34; 0; 5; 24; 23; 9; 16; 2; 14; 11; 6; 47; 25; 14; 32; 4; 25; 17; 31; 39; 1; 7; 44; 1; 10; 14; 13; 5; 7; 15; 34; 22; 42; 45; 10; 42; 4; 28; 42; 1; 1; 45; 14; 40; 14; 46; 11; 38; 10; 31; 42; 0; 8; 35; 10; 34; 17; 11; 8; 16; 19; 20; 42; 43; 22; 31; 18; 27; 32; 26; 46; 31; 11; 49; 15; 35; 21; 32; 22; 29; 13; 20; 16; 34; 39; 34; 11; 49; 41; 12; 8; 45; 40; 41; 34; 31; 27; 24; 33; 40; 31; 24; 35; 12; 4; 13; 27; 43; 42; 45; 11; 0; 41; 27; 38; 43; 15; 2; 9; 48; 22; 35; 13; 38; 29; 50; 29; 43; 17; 47; 37; 35; 48; 50; 38; 9; 10; 45; 39; 46; 48; 30; 12; 26; 9; 33; 26; 27; 50; 11; 12; 0; 0; 8; 17; 50; 1; 24; 21; 2; 50; 36; 17; 26; 48; 1; 43; 14; 18; 48; 48; 32; 8; 45; 9; 13; 37; 43; 10; 41; 38; 34; 46; 8; 4; 44; 12; 37; 41; 4; 35; 21; 7; 28; 44; 9; 33; 22; 13; 20; 4; 2; 20; 23; 21; 35; 45; 44; 29; 3; 48; 18; 45; 31; 30; 9; 43; 13; 42; 49; 40; 1; 18; 1; 44; 29; 24; 6; 36; 30; 12; 47; 38; 36; 1; 46; 3; 37; 37; 15; 12; 24; 34; 39; 30; 50; 30; 28; 34; 0; 38; 5; 29; 37; 0; 5; 38; 29; 41; 24; 50; 33; 42; 46; 35; 7; 33; 47; 15; 21; 5; 17; 4; 45; 2; 4; 28; 31; 14; 27; 36; 36; 12; 31; 33; 48; 6; 39; 46; 36; 9; 45; 10; 31; 21; 38; 44; 48; 38; 21; 22; 44; 7; 5; 37; 25; 10; 3; 9; 32; 30; 12; 1; 18; 30; 48; 10; 23; 36; 13; 2; 48; 49; 35; 33; 7; 21; 48; 34; 6; 44; 2; 40; 48; 35; 48; 47; 7; 31; 45; 35; 50; 22; 45; 36; 33; 28; 15; 10; 4; 7; 4; 32; 23; 47; 19; 4; 24; 12; 20; 1; 36; 2; 28; 30; 37; 20; 10; 41; 3; 0; 17; 5; 31; 29; 13; 18; 43; 17; 15; 25; 32; 1; 19; 34; 49; 28; 38; 30; 36; 33; 15; 43; 28; 9; 48; 30; 4; 32; 48; 13; 43; 28; 29; 24; 1; 41; 48; 4; 40; 32; 0; 42; 45; 50; 2; 16; 40; 12; 41; 16; 15; 6; 49; 39; 34; 12; 17; 10; 32; 18; 41; 16; 28; 21; 33; 9; 49; 33; 41; 30; 4; 35; 24; 9; 23; 4; 34; 3; 31; 40; 36; 6; 4; 40; 33; 26; 35; 18; 4; 8; 19; 23; 38; 44; 21; 35; 39; 14; 2; 7; 7; 2; 20; 5; 50; 30; 5; 48; 35; 17; 22; 26; 27; 46; 27; 16; 5; 7; 20; 40; 14; 36; 27; 28; 38; 12; 4; 27; 21; 46; 18; 47; 11; 49; 32; 9; 49; 8; 26; 22; 8; 29; 39; 30; 49; 30; 4; 2; 23; 9; 31; 7; 48; 6; 17; 13; 11; 9; 17; 31; 37; 11; 10; 35; 20; 30; 27; 38; 50; 2; 9; 35; 45; 39; 45; 30; 38; 50; 22; 43; 30; 29; 4; 41; 28; 33; 46; 33; 17; 8; 15; 2; 43; 4; 19; 28; 33; 19; 9; 38; 37; 47; 47; 49; 5; 18; 38; 19; 36; 30; 11; 40; 33; 20; 2; 34; 47; 44; 47; 12; 12; 39; 30; 12; 37; 35; 28; 41; 48; 26; 33; 8; 18; 38; 5; 10; 19; 42; 23; 45; 48; 36; 43; 7; 44; 22; 36; 45; 40; 48; 7; 5; 25; 50; 39; 36; 30; 39; 35; 9; 42; 5; 22; 27; 3; 18; 47; 10; 1; 41; 8; 30; 39; 12; 22; 3; 36; 3; 32; 49; 49; 38; 44; 25; 0; 48; 23; 46; 17; 22])
23
+
24
+ let test7 _ = assert_equal 0 (beautifulSplits [47; 45; 25; 21; 6; 9; 26; 23; 0; 28; 2; 4; 14; 12; 49; 30; 29; 47; 5; 44; 6; 23; 9; 29; 21; 32; 18; 43; 25; 17; 16; 33; 22; 49; 48; 36; 35; 47; 23; 37; 0; 0; 16; 1; 2; 17; 13; 2; 3; 24; 34; 17; 11; 48; 20; 42; 47; 47; 46; 34; 43; 8; 21; 12; 21; 2; 11; 6; 20; 27; 14; 39; 23; 2; 40; 24; 46; 21; 25; 20; 13; 33; 6; 2; 10; 39; 2; 21; 35; 39; 20; 18; 50; 15; 4; 15; 7; 14; 40; 45; 25; 31; 13; 13; 1; 48; 20; 46; 23; 46; 1; 30; 47; 25; 50; 11; 47; 34; 40; 9; 34; 42; 0; 46; 17; 4; 31; 42; 4; 47; 15; 9; 37; 31; 45; 35; 34; 13; 10; 19; 38; 50; 7; 2; 37; 14; 23; 5; 29; 0; 15; 8; 7; 37; 37; 11; 20; 23; 18; 40; 43; 13; 7; 48; 32; 36; 47; 37; 49; 6; 20; 15; 22; 38; 40; 50; 22; 22; 0; 18; 44; 3; 4; 40; 37; 31; 18; 42; 0; 4; 3; 33; 18; 12; 10; 18; 18; 5; 4; 6; 40; 22; 43; 42; 28; 22; 46; 46; 29; 16; 36; 1; 20; 25; 8; 2; 36; 40; 1; 43; 24; 12; 49; 1; 23; 26; 20; 31; 22; 36; 35; 24; 32; 38; 0; 12; 36; 3; 31; 21; 19; 12; 31; 45; 17; 43; 10; 3; 3; 8; 37; 42; 11; 3; 34; 11; 32; 22; 23; 34; 36; 23; 17; 38; 26; 9; 49; 19; 11; 33; 37; 46; 39; 24; 28; 5; 49; 39; 21; 47; 12; 15; 20; 15; 50; 14; 5; 5; 31; 49; 37; 35; 15; 20; 40; 33; 37; 6; 12; 4; 46; 22; 27; 16; 48; 2; 32; 43; 39; 22; 35; 9; 8; 14; 27; 15; 28; 33; 7; 46; 46; 28; 28; 45; 10; 27; 19; 15; 34; 42; 10; 4; 26; 40; 16; 14; 3; 13; 13; 13; 31; 36; 43; 28; 35; 32; 24; 41; 17; 40; 43; 3; 44; 50; 17; 29; 41; 37; 49; 42; 9; 24; 36; 31; 39; 0; 48; 42; 21; 16; 49; 20; 15; 37; 21; 42; 48; 47; 36; 41; 14; 3; 18; 48; 24; 9; 0; 38; 43; 32; 12; 2; 25; 37; 2; 8; 5; 29; 3; 3; 29; 11; 19; 49; 36; 7; 1; 45; 48; 28; 42; 23; 13; 11; 14; 42; 4; 0; 4; 22; 33; 26; 9; 33; 3; 42; 30; 4; 28; 2; 23; 32; 3; 23; 26; 46; 26; 1; 9; 22; 48; 28; 4; 31; 26; 44; 13; 18; 12; 11; 15; 49; 9; 24; 23; 42; 23; 42; 7; 46; 37; 0; 33; 26; 40; 33; 49; 3; 28; 27; 49; 35; 11; 38; 43; 26; 13; 23; 17; 14; 10; 31; 42; 33; 12; 15; 14; 15; 8; 47; 12; 13; 50; 35; 31; 35; 38; 18; 12; 47; 36; 29; 6; 21; 26; 9; 15; 36; 18; 12; 18; 10; 29; 4; 23; 16; 28; 0; 30; 32; 7; 40; 39; 37; 49; 24; 44; 19; 37; 41; 15; 13; 18; 50; 48; 35; 48; 5; 8; 5; 30; 47; 30; 46; 8; 38; 17; 6; 4; 48; 41; 26; 13; 28; 47; 16; 22; 31; 1; 32; 37; 0; 46; 12; 33; 46; 23; 25; 37; 40; 28; 16; 43; 47; 25; 42; 14; 17; 7; 24; 31; 4; 31; 8; 13; 2; 8; 4; 16; 35; 37; 30; 10; 40; 24; 30; 41; 11; 14; 45; 21; 12; 5; 23; 8; 47; 44; 11; 23; 40; 10; 40; 42; 19; 15; 29; 30; 47; 9; 26; 26; 13; 2; 9; 36; 15; 22; 30; 41; 45; 33; 35; 45; 22; 0; 46; 45; 40; 33; 6; 19; 11; 17; 40; 46; 44; 48; 47; 47; 19; 45; 14; 33; 15; 24; 20; 13; 10; 12; 7; 28; 13; 2; 32; 36; 20; 7; 24; 1; 17; 0; 50; 22; 34; 18; 40; 41; 46; 40; 31; 39; 36; 4; 30; 28; 0; 29; 10; 7; 48; 2; 13; 50; 23; 45; 3; 50; 22; 40; 46; 3; 32; 36; 28; 39; 50; 25; 35; 38; 50; 1; 47; 26; 31; 36; 40; 29; 10; 4; 5; 28; 1; 2; 18; 7; 39; 30; 50; 48; 23; 16; 1; 1; 48; 29; 43; 44; 30; 25; 26; 27; 34; 2; 4; 19; 3; 32; 37; 31; 16; 20; 49; 50; 5; 13; 24; 1; 28; 6; 10; 8; 23; 25; 4; 28; 44; 27; 18; 38; 12; 41; 25; 48; 22; 29; 41; 23; 27; 47; 3; 34; 33; 21; 3; 8; 10; 32; 28; 4; 13; 41; 3; 14; 41; 33; 34; 13; 47; 49; 11; 11; 27; 13; 46; 24; 8; 35; 36; 13; 22; 44; 20; 27; 7; 31; 37; 48; 39; 6; 33; 8; 28; 14; 28; 24; 27; 25; 8; 42; 43; 14; 23; 20; 22; 15; 10; 7; 49; 3; 46; 9; 9; 3; 30; 8; 14; 45; 41; 47; 43; 2; 48; 23; 3; 1; 34; 18; 41; 19; 12; 32; 28; 35; 1; 33; 17; 3; 36; 43; 9; 2; 32; 11; 38; 8; 45; 9; 40; 13; 1; 16; 33; 44; 4; 26; 46; 28; 38; 1; 14; 17; 42; 11; 44; 43; 26; 24; 39; 34; 28; 14; 18; 22; 18; 37; 29; 27; 43; 43; 37; 30; 9; 46; 22; 20; 35; 31; 40; 33; 14; 17; 8; 19; 16; 25; 41; 27; 1; 18; 25; 21; 6; 25; 38; 28; 37; 40; 10; 50; 41; 18; 22; 14; 25; 25; 42; 25; 8; 26; 2; 25; 40; 36; 22; 45; 19; 18; 30; 2; 40; 28; 15; 41; 11; 30; 1; 32; 31; 43; 45; 48; 49; 36; 44; 14; 38; 35; 49; 29; 27; 43; 25; 49; 8; 3; 14; 48; 3; 20; 37; 36; 5; 16; 15; 4; 46; 45; 9; 37; 39; 33; 7; 26; 47; 45; 14; 50; 47; 15; 48; 13; 1; 14; 13; 41; 43; 3; 2; 47; 24; 4; 13; 40; 27; 10; 16; 32; 25; 46; 20; 13; 18; 46; 9; 14; 3; 22; 26; 13; 18; 8; 3; 40; 48; 13; 30; 15; 17; 29; 5; 44; 48; 13; 18; 31; 20; 27; 32; 8; 30; 42; 45; 8; 50; 12; 21; 48; 43; 24; 17; 4; 8; 7; 4; 50; 4; 8; 7; 42; 1; 13; 46; 3; 38; 7; 24; 47; 36; 26; 14; 16; 16; 5; 42; 37; 5; 6; 45; 34; 15; 0; 21; 8; 11; 37; 17; 40; 48; 19; 34; 23; 9; 11; 8; 48; 49; 26; 9; 23; 16; 0; 42; 13; 40; 15; 40; 11; 13; 0; 5; 48; 27; 40; 27; 7; 15; 31; 43; 29; 38; 18; 7; 23; 18; 27; 25; 43; 5; 27; 15; 44; 47; 42; 28; 23; 6; 5; 33; 39; 48; 29; 22; 45; 46; 28; 47; 33; 3; 14; 2; 32; 27; 9; 31; 44; 2; 27; 47; 36; 32; 19; 11; 27; 11; 23; 39; 43; 8; 43; 31; 35; 27; 34; 48; 22; 11; 36; 33; 42; 22; 2; 39; 1; 15; 9; 17; 44; 32; 29; 17; 29; 13; 31; 13; 12; 45; 38; 25; 0; 22; 6; 25; 36; 6; 32; 38; 19; 9; 28; 39; 35; 35; 0; 34; 4; 4; 36; 37; 4; 5; 43; 43; 37; 25; 11; 5; 17; 45; 7; 37; 8; 10; 17; 34; 47; 22; 45; 29; 22; 40; 6; 7; 27; 12; 27; 21; 26; 32; 0; 11; 20; 15; 29; 6; 14; 0; 26; 13; 23; 1; 1; 20; 14; 27; 14; 12; 27; 31; 15; 38; 5; 11; 21; 26; 36; 33; 29; 10; 25; 25; 44; 44; 33; 15; 49; 45; 22; 37; 25; 48; 5; 38; 48; 42; 38; 13; 40; 19; 15; 14; 45; 9; 22; 25; 39; 6; 7; 6; 31; 24; 25; 41; 19; 41; 6; 48; 33; 33; 32; 18; 20; 21; 10; 10; 2; 45; 8; 44; 24; 40; 2; 43; 10; 50; 50; 33; 34; 25; 0; 23; 15; 10; 7; 17; 6; 10; 42; 1; 3; 27; 42; 6; 23; 41; 42; 3; 2; 15; 7; 23; 41; 9; 7; 18; 11; 11; 41; 48; 12; 43; 41; 14; 24; 42; 0; 50; 20; 19; 50; 9; 10; 4; 46; 46; 23; 29; 27; 11; 0; 22; 26; 43; 21; 26; 36; 35; 7; 6; 46; 37; 43; 43; 46; 36; 5; 12; 16; 39; 4; 35; 23; 35; 3; 22; 44; 34; 38; 13; 25; 46; 4; 36; 21; 29; 6; 16; 49; 29; 22; 12; 23; 3; 7; 3; 23; 17; 25; 38; 49; 26; 21; 48; 34; 50; 13; 38; 5; 26; 33; 45; 47; 33; 2; 18; 33; 3; 19; 48; 37; 2; 6; 34; 21; 35; 36; 24; 41; 35; 18; 4; 16; 42; 45; 24; 47; 48; 44; 28; 18; 13; 18; 13; 46; 1; 1; 1; 3; 15; 33; 6; 31; 49; 5; 8; 24; 35; 22; 22; 45; 18; 11; 36; 2; 10; 29; 3; 7; 8; 19; 5; 8; 34; 44; 28; 33; 41; 38; 0; 33; 8; 37; 35; 2; 25; 24; 4; 49; 25; 3; 1; 12; 3; 49; 44; 32; 3; 9; 26; 41; 2; 50; 47; 44; 0; 34; 46; 8; 28; 7; 8; 14; 19; 30; 8; 21; 19; 47; 6; 16; 32; 38; 15; 2; 39; 44; 13; 33; 36; 30; 9; 42; 17; 35; 42; 22; 36; 42; 37; 0; 40; 31; 33; 18; 22; 23; 20; 50; 22; 6; 9; 33; 7; 24; 40; 25; 2; 35; 0; 45; 12; 25; 14; 44; 4; 9; 38; 24; 21; 7; 47; 49; 27; 16; 33; 8; 42; 4; 17; 37; 41; 5; 25; 39; 13; 7; 23; 12; 23; 39; 29; 38; 2; 21; 15; 31; 43; 21; 5; 35; 45; 2; 50; 10; 0; 30; 12; 4; 32; 34; 22; 25; 13; 32; 31; 24; 1; 47; 4; 31; 33; 26; 29; 23; 12; 1; 23; 45; 41; 13; 44; 0; 14; 30; 32; 44; 29; 3; 10; 29; 14; 31; 14; 44; 16; 47; 36; 45; 30; 46; 41; 20; 3; 14; 11; 20; 5; 27; 6; 34; 49; 3; 13; 8; 19; 7; 33; 24; 45; 38; 29; 19; 16; 2; 27; 42; 36; 30; 17; 24; 28; 5; 46; 34; 6; 46; 28; 24; 32; 41; 21; 26; 1; 18; 12; 47; 45; 9; 11; 35; 21; 35; 5; 16; 39; 9; 24; 36; 35; 38; 14; 15; 24; 34; 47; 14; 46; 18; 43; 23; 30; 48; 48; 30; 10; 49; 45; 22; 15; 41; 27; 9; 8; 40; 3; 0; 6; 5; 40; 37; 4; 32; 2; 21; 4; 47; 9; 38; 26; 46; 39; 32; 30; 42; 17; 39; 34; 22; 22; 9; 26; 35; 40; 13; 7; 29; 39; 11; 13; 32; 37; 11; 13; 32; 25; 42; 16; 27; 17; 39; 10; 11; 33; 24; 5; 39; 15; 19; 49; 44; 9; 44; 18; 10; 50; 8; 22; 44; 37; 25; 4; 8; 18; 25; 49; 41; 26; 39; 31; 31; 31; 25; 43; 43; 5; 16; 21; 26; 10; 23; 11; 29; 11; 4; 28; 27; 8; 4; 12; 26; 46; 48; 17; 16; 13; 50; 22; 43; 14; 16; 19; 34; 42; 10; 33; 14; 22; 11; 44; 20; 32; 29; 3; 22; 3; 23; 5; 9; 16; 15; 35; 14; 13; 11; 14; 17; 32; 21; 50; 46; 34; 32; 38; 39; 35; 37; 3; 8; 33; 46; 40; 7; 16; 19; 44; 46; 27; 26; 8; 40; 33; 14; 26; 0; 13; 36; 46; 38; 41; 34; 3; 24; 19; 6; 0; 49; 29; 39; 34; 30; 40; 25; 27; 16; 30; 24; 40; 9; 23; 41; 34; 22; 25; 39; 44; 2; 44; 41; 45; 41; 24; 35; 34; 24; 15; 17; 32; 22; 31; 44; 27; 44; 23; 18; 50; 31; 35; 35; 0; 7; 15; 35; 35; 48; 4; 32; 20; 10; 33; 6; 42; 2; 2; 18; 20; 22; 46; 48; 50; 1; 10; 28; 32; 11; 23; 39; 1; 6; 4; 13; 21; 8; 30; 31; 0; 18; 33; 24; 26; 14; 0; 15; 16; 30; 2; 28; 31; 4; 23; 30; 0; 20; 13; 17; 38; 50; 48; 6; 13; 18; 6; 11; 6; 38; 32; 37; 0; 1; 37; 33; 27; 9; 21; 47; 48; 41; 21; 12; 7; 0; 16; 10; 13; 38; 48; 36; 40; 9; 28; 44; 6; 11; 47; 7; 19; 42; 33; 11; 8; 13; 26; 35; 0; 4; 48; 1; 17; 10; 43; 6; 5; 40; 28; 48; 14; 36; 50; 39; 26; 22; 26; 6; 13; 38; 43; 9; 35; 42; 29; 11; 27; 27; 45; 29; 39; 45; 47; 45; 8; 12; 8; 3; 39; 9; 40; 38; 7; 47; 1; 31; 28; 46; 36; 43; 15; 44; 46; 24; 41; 26; 27; 19; 15; 49; 38; 27; 35; 42; 31; 4; 24; 41; 3; 34; 7; 50; 8; 19; 24; 34; 0; 30; 45; 41; 2; 48; 45; 33; 40; 4; 46; 28; 35; 8; 24; 50; 26; 13; 49; 44; 48; 50; 6; 39; 5; 45; 2; 16; 4; 39; 49; 43; 6; 44; 45; 24; 10; 20; 2; 19; 22; 25; 0; 41; 9; 40; 46; 7; 25; 44; 50; 40; 46; 10; 7; 40; 21; 2; 26; 23; 43; 23; 7; 27; 33; 19; 17; 41; 21; 39; 18; 40; 20; 3; 47; 50; 50; 22; 23; 40; 32; 23; 19; 45; 30; 15; 15; 49; 22; 32; 50; 35; 27; 38; 19; 0; 29; 32; 29; 5; 40; 40; 38; 32; 30; 48; 30; 8; 10; 10; 50; 50; 12; 25; 5; 23; 49; 34; 43; 0; 27; 41; 27; 17; 0; 36; 38; 21; 21; 11; 44; 49; 36; 12; 5; 12; 40; 49; 37; 43; 27; 0; 11; 45; 47; 49; 1; 36; 29; 16; 12; 9; 41; 29; 17; 18; 32; 35; 45; 14; 25; 16; 23; 45; 14; 42; 36; 43; 32; 10; 27; 39; 4; 39; 43; 46; 14; 17; 18; 46; 12; 16; 50; 21; 10; 22; 49; 10; 22; 10; 9; 22; 11; 1; 19; 48; 29; 9; 32; 31; 12; 38; 45; 32; 35; 38; 15; 46; 7; 45; 38; 44; 6; 12; 38; 42; 49; 26; 36; 30; 32; 19; 4; 35; 45; 5; 41; 35; 46; 12; 22; 27; 21; 25; 22; 20; 44; 23; 42; 0; 20; 3; 10; 14; 16; 32; 34; 6; 8; 18; 0; 5; 19; 35; 46; 9; 46; 32; 19; 16; 35; 8; 50; 6; 5; 50; 1; 42; 44; 31; 42; 24; 0; 22; 8; 47; 2; 26; 39; 27; 34; 21; 7; 11; 27; 19; 3; 22; 46; 42; 8; 11; 45; 41; 33; 30; 9; 6; 8; 6; 42; 32; 6; 30; 16; 28; 42; 42; 42; 25; 35; 7; 34; 32; 11; 42; 2; 32; 34; 47; 33; 47; 43; 8; 24; 29; 1; 4; 24; 11; 29; 23; 25; 7; 5; 21; 16; 23; 39; 35; 30; 11; 49; 4; 34; 18; 7; 21; 18; 35; 44; 40; 23; 10; 5; 1; 36; 47; 44; 44; 33; 12; 15; 43; 47; 2; 16; 5; 5; 8; 49; 19; 8; 1; 20; 23; 41; 34; 37; 19; 40; 17; 43; 44; 14; 13; 42; 39; 50; 5; 1; 7; 20; 31; 30; 25; 3; 15; 44; 21; 33; 30; 35; 23; 3; 25; 9; 34; 34; 50; 0; 9; 8; 14; 24; 1; 5; 27; 39; 45; 50; 0; 12; 37; 27; 39; 33; 11; 5; 30; 49; 46; 10; 16; 6; 50; 32; 28; 38; 43; 2; 23; 1; 29; 20; 40; 36; 9; 2; 10; 3; 32; 32; 45; 15; 5; 5; 32; 8; 50; 25; 27; 49; 0; 4; 29; 11; 38; 0; 0; 31; 27; 32; 6; 50; 25; 18; 29; 40; 33; 22; 28; 43; 9; 48; 12; 50; 33; 3; 22; 30; 44; 28; 6; 3; 24; 17; 16; 30; 32; 49; 50; 3; 42; 14; 32; 1; 33; 33; 43; 46; 8; 36; 3; 13; 6; 18; 25; 12; 6; 27; 5; 50; 3; 38; 6; 33; 14; 31; 15; 8; 13; 26; 7; 3; 21; 20; 41; 20; 44; 2; 15; 27; 28; 22; 14; 10; 13; 48; 6; 47; 0; 33; 42; 7; 30; 39; 20; 34; 27; 34; 22; 2; 37; 8; 23; 34; 47; 16; 6; 19; 10; 36; 21; 49; 28; 31; 44; 31; 25; 7; 47; 20; 39; 35; 6; 4; 25; 47; 50; 30; 16; 7; 34; 18; 20; 3; 39; 38; 16; 0; 6; 45; 1; 31; 9; 46; 31; 26; 49; 11; 11; 33; 1; 37; 29; 13; 33; 19; 49; 17; 18; 33; 20; 7; 28; 24; 44; 18; 10; 34; 26; 1; 19; 36; 4; 36; 8; 27; 45; 18; 11; 23; 28; 46; 24; 44; 35; 19; 27; 12; 38; 10; 5; 48; 49; 0; 50; 36; 18; 25; 35; 12; 25; 40; 41; 24; 34; 28; 35; 31; 48; 5; 46; 8; 14; 3; 47; 4; 33; 1; 23; 10; 1; 19; 32; 2; 32; 48; 5; 2; 10; 3; 48; 41; 0; 11; 27; 13; 23; 23; 18; 26; 24; 17; 44; 42; 34; 46; 50; 8; 30; 40; 45; 42; 15; 49; 21; 18; 10; 34; 45; 36; 15; 5; 15; 50; 42; 6; 28; 45; 20; 46; 24; 44; 19; 13; 22; 46; 6; 48; 34; 11; 42; 38; 16; 16; 50; 23; 14; 32; 20; 23; 35; 7; 46; 0; 11; 48; 50; 35; 21; 5; 41; 23; 23; 17; 8; 8; 26; 0; 36; 26; 19; 18; 30; 11; 18; 33; 21; 12; 12; 47; 32; 38; 3; 11; 14; 20; 16; 8; 33; 29; 14; 16; 42; 19; 25; 28; 6; 41; 27; 45; 24; 34; 6; 3; 34; 38; 49; 32; 44; 42; 18; 7; 26; 21; 2; 8; 41; 23; 45; 44; 46; 36; 46; 40; 2; 48; 29; 43; 35; 21; 4; 39; 1; 9; 35; 2; 9; 0; 14; 37; 17; 8; 25; 32; 47; 47; 16; 17; 27; 31; 9; 4; 15; 34; 17; 41; 50; 8; 26; 43; 12; 31; 44; 11; 19; 31; 29; 8; 2; 50; 21; 5; 36; 28; 1; 30; 35; 45; 17; 34; 45; 48; 2; 41; 4; 28; 22; 9; 12; 41; 0; 12; 48; 42; 3; 12; 31; 30; 33; 32; 41; 35; 19; 5; 2; 25; 19; 46; 32; 8; 6; 45; 35; 12; 7; 38; 35; 30; 35; 30; 1; 37; 43; 44; 20; 50; 48; 4; 5; 1; 40; 5; 4; 47; 8; 26; 43; 46; 29; 21; 28; 4; 45; 17; 36; 16; 16; 28; 18; 1; 37; 27; 25; 49; 18; 6; 8; 30; 19; 9; 19; 4; 30; 2; 17; 29; 17; 41; 18; 34; 3; 37; 46; 5; 45; 31; 43; 23; 40; 43; 19; 45; 4; 38; 37; 46; 35; 49; 0; 21; 5; 49; 45; 21; 50; 5; 32; 42; 31; 31; 13; 19; 47; 34; 40; 1; 9; 36; 36; 48; 7; 49; 33; 2; 17; 22; 28; 41; 23; 29; 9; 26; 11; 44; 12; 9; 18; 13; 39; 4; 18; 2; 14; 30; 20; 26; 19; 48; 10; 15; 6; 48; 16; 15; 14; 41; 32; 16; 49; 42; 7; 37; 16; 35; 9; 11; 50; 41; 23; 37; 37; 13; 32; 37; 17; 28; 2; 19; 2; 28; 18; 12; 38; 8; 24; 26; 48; 21; 48; 23; 18; 44; 32; 31; 48; 22; 6; 16; 6; 27; 10; 12; 16; 30; 19; 24; 41; 21; 31; 12; 2; 28; 19; 28; 34; 49; 12; 38; 13; 21; 27; 37; 4; 29; 23; 34; 50; 5; 50; 36; 16; 35; 46; 39; 33; 37; 50; 46; 45; 30; 6; 34; 15; 43; 25; 12; 41; 26; 50; 7; 32; 32; 21; 30; 47; 4; 29; 8; 33; 36; 48; 10; 3; 23; 18; 23; 43; 9; 45; 45; 21; 41; 15; 8; 9; 42; 16; 17; 2; 37; 25; 36; 12; 15; 4; 49; 46; 32; 6; 44; 12; 49; 31; 3; 47; 15; 3; 2; 8; 28; 41; 18; 44; 22; 11; 28; 2; 25; 26; 38; 2; 22; 38; 34; 39; 4; 15; 47; 40; 36; 34; 9; 29; 46; 36; 27; 26; 14; 12; 1; 28; 8; 29; 19; 30; 28; 46; 1; 4; 28; 39; 25; 47; 17; 18; 37; 5; 17; 0; 34; 39; 6; 24; 1; 50; 15; 10; 45; 48; 7; 18; 23; 32; 28; 38; 46; 24; 33; 45; 32; 50; 34; 31; 35; 40; 8; 40; 14; 19; 14; 48; 39; 18; 32; 36; 27; 0; 1; 39; 46; 48; 37; 46; 30; 0; 5; 8; 23; 42; 42; 10; 2; 9; 47; 50; 30; 19; 25; 1; 28; 8; 46; 30; 44; 50; 22; 20; 7; 15; 14; 1; 24; 32; 41; 5; 16; 1; 8; 20; 3; 6; 37; 15; 45; 21; 49; 28; 37; 43; 27; 22; 12; 38; 2; 10; 27; 32; 40; 40; 30; 13; 41; 25; 33; 6; 5; 39; 17; 7; 13; 11; 41; 0; 3; 49; 35; 33; 21; 41; 38; 9; 1; 43; 6; 50; 10; 30; 1; 20; 11; 50; 29; 1; 9; 33; 36; 40; 43; 5; 28; 48; 4; 44; 11; 9; 43; 32; 48; 20; 7; 13; 0; 42; 40; 27; 42; 12; 46; 18; 45; 25; 19; 17; 33; 49; 38; 30; 1; 13; 21; 12; 41; 26; 36; 11; 28; 14; 45; 43; 20; 10; 21; 29; 0; 24; 25; 0; 43; 36; 18; 47; 31; 5; 9; 15; 41; 25; 0; 48; 3; 37; 19; 24; 36; 32; 6; 47; 32; 22; 35; 16; 40; 38; 23; 2; 39; 27; 31; 2; 11; 37; 38; 44; 40; 46; 29; 31; 42; 13; 46; 6; 47; 16; 28; 23; 42; 40; 48; 25; 35; 41; 45; 21; 15; 11; 7; 27; 2; 17; 44; 40; 2; 19; 40; 9; 4; 14; 8; 47; 10; 26; 33; 29; 25; 41; 0; 49; 1; 37; 17; 16; 12; 50; 46; 37; 8; 10; 1; 5; 24; 16; 43; 8; 9; 20; 37; 2; 1; 4; 45; 34; 28; 21; 50; 8; 46; 38; 16; 38; 12; 11; 20; 47; 44; 34; 42; 27; 26; 13; 6; 40; 8; 4; 36; 18; 10; 47; 2; 48; 5; 50; 38; 37; 16; 39; 16; 50; 4; 23; 16; 44; 6; 20; 37; 50; 40; 25; 50; 29; 30; 42; 21; 37; 5; 45; 1; 34; 28; 26; 3; 4; 18; 20; 39; 5; 22; 35; 47; 34; 7; 24; 33; 50; 43; 0; 23; 11; 32; 18; 22; 25; 6; 29; 23; 29; 36; 6; 44; 39; 44; 0; 3; 8; 16; 41; 22; 21; 1; 24; 18; 18; 33; 24; 39; 8; 26; 6; 50; 17; 3; 30; 41; 44; 1; 11; 2; 3; 42; 19; 2; 30; 16; 1; 22; 18; 46; 2; 33; 10; 3; 36; 43; 41; 41; 50; 20; 21; 28; 33; 45; 14; 24; 24; 33; 16; 11; 44; 35; 24; 50; 23; 33; 7; 17; 20; 11; 49; 27; 22; 39; 19; 21; 44; 33; 36; 39; 5; 50; 6; 0; 16; 16; 28; 36; 42; 47; 45; 18; 36; 35; 18; 47; 7; 45; 44; 37; 24; 12; 35; 25; 26; 10; 13; 3; 29; 14; 16; 26; 45; 43; 9; 33; 25; 3; 42; 33; 18; 30; 28; 7; 18; 1; 33; 50; 20; 41; 6; 35; 9; 15; 23; 48; 25; 1; 33; 3; 24; 16; 10; 42; 50; 10; 20; 28; 32; 45; 32; 9; 21; 20; 10; 16; 10; 36; 8; 49])
25
+
26
+
27
+ (* Grouping test cases *)
28
+ let suite = "Test Suite for beautifulSplits" >::: [
29
+
30
+ "test1" >:: test1;
31
+ "test2" >:: test2;
32
+ "test3" >:: test3;
33
+ "test4" >:: test4;
34
+ "test5" >:: test5;
35
+ "test6" >:: test6;
36
+ "test7" >:: test7;
37
+ ]
38
+
39
+
40
+ (* Running the tests *)
41
+ let () = run_test_tt_main suite
42
+ end
count_beautiful_splits_in_an_array/scala_tests/MySuite.scala ADDED
@@ -0,0 +1,32 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ class MySuite extends munit.FunSuite {
3
+
4
+ test("test1") {
5
+ assertEquals(Main.beautifulSplits(List(1,1,2,1)), 2)
6
+ }
7
+
8
+ test("test2") {
9
+ assertEquals(Main.beautifulSplits(List(1,2,3,4)), 0)
10
+ }
11
+
12
+ test("test3") {
13
+ assertEquals(Main.beautifulSplits(45,49,1,42,22,45,43,32,47,38,3,12,8,33,5,47,14,30,31,40,22,18,40,46,48,7,37,36,42,41,23,8,37,34,24,7,27,0,16,27,17,22,44,20,41,36,46,9,27,32,17,0,4,42,18,9,35,2,34,14,5,42,43,49,47,5,15,31,8,28,22,18,28,34,47,41,16,0,43,45,16,1,18,41,14,49,3,6,40,17,31,32,5,8,4,39,27,23,40,21,44,19,47,6,48,3,37,2,15,39,37,20,23,17,45,18,12,18,24,11,14,30,29,46,2,40,23,40,1,49,26,4,8,33,48,3,22,47,36,20,17,30,45,8,37,33,4,13,11,31,44,26,14,46,20,10,33,30,11,44,35,46,41,17,0,42,25,21,1,46,20,1,2,31,35,9,48,36,46,37,25,36,30,30,27,41,49,22,5,9,10,13,36,50,11,18,24,10,33,21,42,8,4,1,13,4,24,29,41,8,23,2,29,22,28,42,50,24,35,19,10,14,46,45,1,14,47,21,44,14,20,44,49,23,13,44,39,5,24,31,31,15,2,46,30,36,49,16,44,9,27,21,47,34,22,43,40,16,10,6,20,50,46,11,7,14,35,19,17,42,25,8,28,24,13,21,10,28,48,43,38,16,12,39,21,49,10,30,39,46,19,6,21,5,40,16,6,42,32,11,5,14,47,7,21,11,47,32,28,23,25,25,40,35,32,3,24,36,37,33,19,36,43,45,41,45,42,27,28,21,27,30,35,33,24,30,49,16,20,5,35,10,18,9,17,43,39,37,22,8,28,39,49,23,22,11,37,28,19,26,42,3,40,9,16,37,3,39,18,10,7,46,44,20,21,27,49,41,29,12,43,45,1,13,47,17,1,3,26,44,38,33,39,35,18,28,14,40,41,8,12,43,17,21,42,29,15,36,38,7,35,4,3,46,46,21,23,26,42,47,18,12,4,36,17,21,45,14,19,28,32,6,10,47,2,2,14,4,12,16,28,30,2,20,11,36,10,41,27,19,45,15,39,32,25,7,12,29,29,33,11,7,19,48,21,26,28,24,31,31,30,21,23,8,36,38,9,26,23,25,13,30,47,2,30,49,42,35,30,28,39,9,17,22,24,47,28,9,40,18,28,0,6,49,45,18,20,18,28,11,27,35,25,35,47,9,47,8,3,2,15,27,3,45,11,43,3,13,13,14,42,14,23,0,16,15,9,32,7,4,29,36,43,24,11,40,44,22,5,48,11,50,35,42,43,29,10,11,50,25,24,49,50,28,0,40,32,4,7,40,37,50,5,12,0,24,38,40,49,26,5,7,16,21,30,19,27,1,25,40,40,45,19,12,2,32,15,41,9,46,1,29,31,6,20,44,50,19,9,25,47,18,47,39,20,18,10,31,35,6,14,12,29,0,20,9,12,29,9,47,24,24,38,44,3,18,42,13,28,18,45,18,14,13,4,32,12,21,45,15,50,9,39,36,7,25,33,12,39,38,34,7,12,22,19,8,7,36,12,31,30,16,3,6,0,47,12,31,47,2,27,1,33,48,4,44,2,24,12,26,35,39,26,25,19,4,9,14,33,3,6,5,34,5,17,19,29,30,15,33,22,47,15,35,3,1,32,31,31,2,37,18,38,3,13,31,33,24,42,20,5,15,21,36,30,38,30,31,1,5,16,21,46,2,11,49,41,26,39,44,43,1,24,20,50,13,35,8,16,48,28,44,18,10,3,28,6,40,6,33,38,43,25,12,21,45,33,29,10,20,24,8,4,39,44,3,41,31,47,49,30,13,48,21,7,13,29,37,49,15,28,12,26,43,46,42,22,2,36,49,46,41,6,29,25,48,26,20,26,5,35,48,32,41,12,42,42,34,4,35,33,48,12,40,6,20,34,9,35,30,19,9,30,4,40,37,21,40,37,37,43,3,26,7,28,6,22,27,14,1,26,50,25,9,37,8,29,22,46,38,17,0,22,33,23,20,16,42,49,25,32,10,38,4,45,47,29,18,33,1,42,19,29,17,39,23,14,9,26,33,34,19,6,22,9,7,26,12,38,4,31,18,11,21,47,11,1,5,28,16,46,32,46,22,23,27,0,23,45,6,48,25,17,42,40,38,43,50,49,2,24,33,47,49,26,29,8,21,47,29,23,50,8,39,45,42,49,13,41,48,3,37,5,12,35,43,40,26,30,28,36,24,40,26,50,2,6,15,31,46,30,21,35,3,19,6,14,4,25,25,18,4,39,5,29,30,46,9,50,24,10,8,50,41,8,14,4,34,31,41,45,29,37,25,40,23,30,2,5,42,16,16,8,10,10,18,49,25,37,5,48,2,39,47,39,36,26,11,6,43,30,11,48,10,32,37,14,20,47,40,9,14,8,20,5,35,22,48,27,34,2,15,21,44,11,22,40,11,27,32,23,41,33,16,31,38,18,39,45,1,40,24,20,33,4,23,42,37,14,9,36,35,38,49,2,11,43,31,17,31,8,0,14,31,37,26,50,6,48,41,18,46,47,45,4,10,12,19,0,44,45,7,38,8,9,38,24,46,37,3,16,8,8,2,46,48,12,19,38,8,22,7,1,32,43,16,16,15,40,31,12,26,25,46,20,6,31,29,29,47,32,17,31,37,25,26,28,1,44,19,7,39,39,22,30,9,37,19,2,34,2,50,12,35,27,16,33,5,35,30,25,4,20,8,1,10,43,50,32,10,39,14,24,32,4,14,0,14,47,31,16,15,11,33,35,33,34,6,28,26,32,8,3,32,40,42,31,22,38,48,0,39,10,37,48,43,41,0,43,3,35,35,11,12,34,4,42,16,18,30,36,36,25,3,17,46,42,48,42,47,22,34,31,10,26,7,38,15,6,21,7,7,46,46,7,21,23,27,49,30,29,21,1,46,10,3,38,38,38,9,43,0,12,0,3,18,28,16,9,26,46,8,12,38,34,25,30,31,13,2,26,36,49,27,23,17,46,26,33,26,22,44,21,4,42,12,27,35,21,42,46,12,20,46,40,39,7,26,17,19,37,10,22,45,35,4,9,35,28,13,2,36,46,30,25,2,41,27,28,14,47,43,36,39,31,34,24,3,50,30,7,27,14,29,30,33,40,49,45,41,8,38,41,49,0,26,43,48,13,34,45,32,46,12,0,1,11,14,48,15,14,17,19,13,41,23,8,25,46,36,47,43,8,2,15,32,15,16,13,39,23,3,45,34,22,7,19,11,40,18,29,34,48,18,25,33,7,14,2,21,46,37,2,24,15,6,21,46,8,17,14,27,29,46,48,43,30,25,30,33,50,25,21,39,42,5,11,50,38,4,16,46,7,34,37,12,41,14,15,46,1,26,16,27,21,43,23,27,42,35,28,1,32,9,17,32,13,36,26,37,30,12,50,18,39,10,11,36,10,32,35,9,32,4,46,26,13,14,30,25,44,22,37,11,24,1,7,21,47,38,2,10,27,6,41,29,0,22,22,40,16,13,31,21,22,22,32,30,14,42,8,50,10,17,4,7,36,40,45,43,36,42,17,26,32,29,46,8,17,46,40,24,28,28,45,4,14,28,30,9,39,39,19,1,29,38,5,36,14,0,27,25,29,22,10,37,27,37,23,5,23,40,43,48,6,18,28,4,12,5,30,49,40,45,10,15,50,26,37,27,32,29,22,8,43,39,22,16,27,4,41,31,39,26,31,28,34,50,10,2,15,50,14,23,40,44,49,29,16,38,25,2,15,11,33,10,22,26,42,19,24,21,38,38,4,35,23,9,9,6,18,19,30,34,43,48,45,47,31,2,13,16,17,22,45,26,48,44,8,9,28,32,17,34,17,25,27,49,44,30,39,12,44,28,15,5,9,19,31,26,19,32,0,21,13,6,2,24,36,25,5,33,12,47,20,38,31,37,7,23,47,44,0,26,45,47,1,35,32,5,29,5,20,44,18,34,5,39,42,16,41,5,31,2,36,46,13,30,25,43,36,21,21,47,50,43,35,19,26,21,28,16,18,25,49,36,9,11,9,8,25,18,48,45,28,2,17,50,10,34,17,15,19,5,22,45,23,48,45,30,46,36,16,46,9,31,28,15,42,50,6,5,20,7,20,50,46,29,0,0,37,13,50,37,43,47,13,10,0,27,38,7,31,19,41,25,48,45,32,23,10,45,32,30,0,21,32,4,35,21,47,45,11,1,35,14,5,27,31,5,38,18,30,47,43,30,19,16,49,34,24,7,44,47,36,15,28,14,48,44,10,19,47,9,45,32,16,0,30,13,37,20,50,8,4,50,43,22,0,24,46,28,39,20,10,50,46,9,20,19,47,27,7,1,6,7,34,3,16,37,35,21,48,29,25,9,16,41,42,28,48,44,7,2,19,35,38,8,14,2,34,36,50,13,32,47,18,9,15,47,0,6,6,30,0,3,19,48,39,12,19,20,15,30,17,44,21,21,20,15,1,2,29,45,16,4,35,31,15,34,37,45,22,27,8,36,4,38,14,16,49,12,21,35,37,42,11,46,9,32,30,35,27,14,7,46,1,27,14,0,14,16,4,5,28,45,1,27,25,23,31,27,17,41,23,50,38,48,35,41,15,32,43,3,39,10,29,28,7,15,40,49,3,45,41,34,30,31,43,11,26,28,27,46,46,24,37,35,41,8,34,17,11,32,8,42,27,1,38,12,37,32,40,38,20,43,45,44,5,31,1,12,37,38,6,50,39,22,25,30,14,19,23,25,1,8,11,31,49,13,50,28,37,42,24,17,34,14,48,8,50,13,49,41,6,25,6,26,41,50,40,10,12,20,22,27,18,7,10,44,42,6,26,47,15,26,16,24,14,24,40,10,9,10,45,8,10,45,2,41,10,23,44,33,31,1,1,8,11,10,32,6,24,43,9,40,43,46,34,12,27,38,14,13,10,17,24,47,10,31,21,44,45,4,14,11,19,24,23,13,49,23,46,22,25,25,8,11,46,50,3,21,0,12,16,2,3,45,1,0,8,31,31,40,14,1,8,41,2,7,31,7,8,2,30,29,38,39,43,18,24,42,38,49,3,32,17,3,37,34,13,35,3,16,22,16,2,23,10,12,37,19,15,16,17,48,6,10,25,35,4,29,12,36,34,25,15,11,47,2,7,29,7,22,23,7,25,4,26,20,3,48,14,3,15,44,37,12,5,25,32,26,10,25,44,2,50,4,2,39,16,23,3,1,4,11,6,32,35,7,34,6,31,37,7,40,0,15,1,9,28,29,0,22,22,14,31,41,0,15,42,15,40,20,50,45,26,27,29,33,29,18,33,24,0,12,44,47,4,1,2,8,44,24,0,47,39,34,27,34,7,6,47,18,41,11,11,25,22,46,11,14,26,4,32,29,16,29,47,14,36,23,14,11,50,4,1,24,42,23,13,47,44,38,18,1,14,34,36,18,14,17,41,23,16,45,19,16,38,49,39,20,2,35,3,12,21,26,17,34,32,32,5,46,10,30,47,48,31,8,5,50,17,44,26,2,30,40,39,46,13,33,36,47,0,20,33,46,31,13,28,46,37,35,7,39,23,28,5,10,21,31,47,18,22,44,0,12,34,15,37,35,34,12,22,34,37,7,43,1,14,28,46,39,0,42,26,12,9,8,40,19,7,5,32,14,19,15,15,50,22,31,38,19,18,18,2,47,36,7,3,19,3,9,25,4,3,25,14,12,1,13,21,29,36,21,17,46,27,16,2,9,41,39,29,23,21,20,49,32,2,32,40,30,43,14,17,27,45,16,31,25,40,26,18,35,40,36,24,32,39,1,24,8,39,13,5,50,13,34,18,33,16,48,10,13,40,27,14,15,37,49,0,24,3,13,10,46,9,20,31,20,35,38,35,5,9,20,47,8,4,25,44,5,22,28,14,40,42,18,9,14,40,29,20,25,4,32,34,6,24,9,39,29,21,38,19,19,4,15,23,37,33,29,33,25,0,14,4,41,50,19,27,4,9,37,16,5,7,24,2,23,12,19,30,25,42,4,0,31,44,9,38,40,11,28,44,43,9,50,2,11,29,47,7,8,39,32,22,14,13,5,35,48,10,30,28,12,2,25,29,23,19,16,23,24,9,25,38,50,36,2,44,35,7,3,15,50,21,49,42,32,5,9,7,8,48,34,41,21,39,15,2,13,35,47,2,22,2,2,16,12,16,28,43,37,12,37,26,22,19,41,28,24,20,43,19,47,50,13,28,43,17,13,33,11,34,28,16,48,24,49,23,9,11,15,48,7,16,50,23,45,14,44,1,31,39,43,17,49,28,6,28,34,13,11,9,7,25,20,19,39,40,7,6,18,18,18,36,15,28,37,42,26,18,37,12,3,36,0,45,1,29,35,31,20,33,42,2,9,2,42,46,24,17,29,17,1,49,26,32,36,9,23,46,47,35,46,47,11,30,15,1,47,49,10,25,29,12,28,13,36,50,36,11,30,50,22,1,13,6,2,8,3,14,26,4,35,9,42,6,47,17,39,46,3,19,44,23,39,14,34,48,24,4,20,50,41,9,43,41,10,37,29,42,40,37,0,32,10,21,17,11,17,7,38,27,11,41,43,25,35,3), 49)
14
+ }
15
+
16
+ test("test4") {
17
+ assertEquals(Main.beautifulSplits(43,13,15,5,4,43,7,6,22,28,34,41,26,38,37,23,41,15,5,35,41,8,21,14,12,30,16,49,10,47,2,43,24,19,50,47,9,29,28,45,31,39,16,45,1,30,18,13,15,2,9,11,32,32,32,26,47,22,4,18,26,38,41,39,39,37,40,1,16,10,30,13,25,34,6,7,12,25,14,4,2,3,38,40,20,32,26,20,17,7,1,12,44,49,47,5,20,6,15,3,29,8,50,4,0,43,29,45,27,14,43,18,23,37,29,35,21,23,49,45,3,48,43,22,2,3,21,20,25,27,46,22,0,21,7,40,46,8,19,43,7,50,2,32,5,15,44,32,16,29,21,32,0,36,9,10,14,44,25,13,5,25,11,33,4,2,47,32,35,35,34,10,8,17,1,9,31,43,11,19,31,21,25,16,17,15,47,32,48,30,47,3,6,23,24,6,6,33,1,47,9,7,42,10,34,17,21,27,3,50,10,41,12,27,17,14,19,14,19,26,29,32,7,0,45,18,0,12,4,29,7,44,43,14,35,13,26,26,42,15,44,41,3,37,23,7,23,32,18,35,2,46,2,47,14,29,48,21,13,43,34,50,11,47,36,10,19,32,6,4,19,4,27,17,13,13,13,32,17,15,22,36,12,21,29,16,29,18,28,37,46,43,33,28,43,17,13,31,22,35,21,13,4,43,7,11,26,16,7,8,36,6,12,15,11,40,34,35,17,13,28,49,35,20,14,31,45,39,13,17,15,48,41,21,48,18,36,24,22,1,44,14,17,4,13,17,9,47,42,29,8,19,10,36,17,49,24,48,26,26,22,13,40,27,7,26,37,40,20,11,18,39,19,30,1,27,45,29,48,43,24,35,8,39,11,10,5,8,11,25,33,25,44,15,27,12,21,31,38,42,36,10,11,25,19,22,30,0,33,11,16,0,46,28,34,31,21,40,32,28,50,46,41,11,7,16,18,4,8,47,39,29,40,41,21,15,39,5,31,11,28,21,39,40,29,42,23,38,45,44,17,41,21,43,17,46,17,45,50,16,26,19,9,3,11,3,33,47,32,18,39,31,20,2,13,32,34,9,14,6,32,49,5,16,21,25,33,32,34,4,19,2,31,2,13,45,29,37,46,4,2,18,24,2,48,42,44,46,21,49,26,3,22,24,44,45,36,27,21,16,35,49,31,26,46,1,45,44,3,18,20,15,44,31,38,46,16,20,44,44,48,41,8,36,1,2,40,44,21,33,16,26,49,9,12,6,33,41,33,8,45,37,48,37,12,40,41,27,1,1,7,7,45,24,0,48,8,16,32,21,34,46,46,9,38,43,7,33,38,2,41,40,1,13,47,33,47,22,48,46,34,32,44,8,41,13,20,22,23,27,27,18,14,21,12,30,17,6,22,11,5,21,35,39,39,22,2,38,7,35,22,47,21,32,19,25,4,13,31,18,41,12,41,40,13,12,12,7,2,10,10,5,13,10,2,42,17,46,43,19,4,27,33,48,28,42,36,34,7,22,28,38,20,10,39,29,42,34,11,10,10,7,11,8,10,49,4,40,35,10,2,11,41,21,28,2,21,34,19,3,21,28,40,10,16,15,25,0,3,22,2,34,33,13,0,3,4,12,29,19,45,28,41,40,33,13,15,33,8,38,39,31,26,48,35,18,46,32,43,32,7,32,11,25,0,30,10,10,18,49,30,49,30,39,48,50,1,6,9,44,4,33,37,28,11,10,5,1,22,0,3,16,13,17,18,9,12,40,14,46,42,49,31,50,49,6,11,23,44,29,42,6,43,20,23,48,38,26,39,12,43,13,20,32,8,0,24,50,43,9,23,49,26,19,24,42,7,24,18,22,48,35,7,1,6,46,37,35,4,29,35,21,0,32,39,5,44,14,11,45,13,47,24,29,20,19,31,9,20,38,34,3,38,34,33,48,10,20,33,20,11,12,47,34,44,46,44,9,31,14,42,17,22,25,9,43,33,6,24,49,24,38,34,13,2,25,12,28,32,19,21,0,8,45,50,11,36,0,32,15,30,3,18,20,46,7,24,24,47,8,7,47,28,27,29,25,0,16,15,37,20,36,5,32,50,41,44,10,29,23,49,21,13,19,32,16,44,8,9,40,47,42,24,38,31,49,28,40,44,2,7,25,37,23,8,11,12,7,41,23,29,12,4,6,38,26,5,15,28,19,13,50,29,31,48,39,18,38,30,21,7,14,8,3,49,11,10,2,35,22,9,20,40,6,37,32,26,24,22,13,41,29,15,30,10,12,47,18,15,10,5,20,36,49,0,35,17,3,44,46,16,2,2,20,1,13,31,30,39,5,47,31,5,35,43,28,21,4,49,9,25,46,1,37,16,42,32,34,5,43,24,14,48,9,32,16,44,0,9,28,39,12,4,31,20,4,7,2,45,15,7,37,43,31,31,17,29,22,20,25,11,30,46,3,42,13,47,38,6,0,17,45,3,3,1,9,36,26,45,43,14,1,32,16,10,44,19,24,5,33,1,7,44,10,40,47,7,3,34,34,28,8,37,28,41,41,12,19,34,18,11,30,4,36,4,23,9,40,31,12,37,22,23,17,50,48,0,9,45,16,46,6,47,3,48,42,48,11,30,21,39,46,29,29,36,45,29,49,34,25,34,13,40,19,14,4,21,23,9,14,5,13,38,6,43,22,34,13,21,33,8,46,30,44,17,29,43,48,23,42,21,7,8,21,4,32,19,25,1,10,3,35,4,49,40,23,41,23,10,28,10,31,7,39,38,47,20,29,20,6,23,24,31,23,7,7,39,31,29,11,1,31,27,36,28,2,42,45,50,4,19,43,42,26,0,40,12,6,23,48,3,37,8,50,46,17,46,35,23,1,31,25,7,11,43,24,40,31,37,47,11,43,3,7,38,8,47,40,47,25,26,4,5,19,41,41,21,23,18,39,44,46,9,28,25,38,49,15,46,43,45,28,13,3,2,16,22,29,36,50,42,48,44,47,9,32,34,17,45,3,40,25,35,43,16,9,26,27,15,10,14,7,33,23,50,1,1,0,14,26,15,38,8,22,30,23,9,50,49,5,47,15,21,31,6,41,8,26,48,34,0,20,37,33,44,1,3,35,45,40,34,18,46,10,9,39,29,42,47,12,5,11,25,9,50,24,33,27,34,25,38,48,17,38,7,31,42,33,38,47,46,40,22,0,10,1,8,8,22,29,4,32,26,4,38,10,24,11,28,23,49,16,12,13,15,30,3,24,39,40,11,48,40,25,17,48,42,49,24,3,2,15,39,34,38,34,41,4,40,11,30,7,31,19,16,19,49,22,2,15,20,2,30,38,33,11,37,49,48,46,27,36,25,47,8,15,48,2,0,45,43,36,26,34,3,18,34,31,30,7,22,2,34,46,33,15,36,44,31,38,47,43,50,24,46,9,11,10,22,4,14,25,16,27,38,0,42,7,18,22,23,2,31,27,28,48,34,31,47,35,21,45,40,7,35,42,23,44,16,6,24,40,38,37,46,4,39,37,30,5,31,30,11,26,47,40,11,22,37,4,17,4,42,9,49,14,47,9,24,18,6,37,2,2,39,31,13,29,50,32,25,5,16,34,46,30,32,45,10,44,10,3,44,2,48,7,38,44,46,39,6,9,32,33,48,16,3,35,43,27,15,22,1,19,4,16,10,8,27,23,0,50,10,37,43,42,25,16,25,15,32,28,34,15,11,49,7,17,0,33,0,42,27,5,1,16,11,40,46,38,23,37,44,18,6,8,41,2,38,45,33,45,15,8,42,15,4,37,45,18,28,16,50,26,40,38,21,32,20,33,40,25,30,1,27,38,1,35,20,33,11,48,2,37,27,13,31,9,8,27,47,41,32,43,24,28,40,17,35,15,38,28,35,35,37,20,29,31,26,11,13,41,29,16,24,50,36,35,39,26,17,27,48,28,13,42,15,22,44,7,50,29,19,2,38,30,33,44,22,20,13,37,10,27,48,22,47,45,0,2,47,5,45,10,1,8,16,40,10,50,23,25,40,27,39,24,36,37,31,48,46,11,37,24,50,9,4,15,47,39,34,46,14,6,1,11,16,13,29,4,47,21,47,41,41,13,3,48,32,21,7,15,10,31,23,48,40,25,37,5,46,39,5,6,48,47,17,2,20,30,43,12,46,46,14,41,7,33,45,46,35,14,0,44,7,27,34,5,6,6,3,31,27,23,33,29,46,16,42,4,4,42,3,2,40,7,34,23,20,17,17,5,23,41,50,45,37,27,11,50,12,19,9,7,20,44,50,38,13,20,1,42,3,1,21,11,25,23,27,33,49,22,10,23,15,49,3,11,41,37,15,42,5,25,44,46,11,6,2,1,50,36,34,36,36,32,29,26,12,26,27,4,15,40,49,26,41,46,45,20,50,12,0,12,4,2,17,37,5,36,41,32,6,49,4,49,1,11,42,50,31,18,18,32,27,47,49,22,25,3,12,48,46,28,0,37,26,18,29,49,33,20,36,41,27,3,15,21,17,34,50,34,6,13,33,41,21,44,29,30,27,4,15,30,25,41,9,50,12,42,4,22,35,4,28,27,22,13,34,23,10,14,1,1,31,13,8,22,30,23,38,11,6,10,32,25,39,6,35,26,38,23,17,46,42,17,14,41,1,30,3,15,27,48,18,33,3,6,8,13,1,26,25,12,33,13,39,40,45,1,27,16,44,25,19,6,25,34,41,31,18,14,5,35,44,18,25,33,24,21,47,45,26,2,4,43,20,43,22,9,37,22,25,35,25,24,22,9,8,39,45,19,25,41,21,45,15,46,34,31,26,37,10,22,39,47,37,14,0,26,20,13,8,48,1,9,12,47,20,26,50,41,35,15,50,34,40,36,11,23,24,11,0,20,28,18,7,23,3,29,6,50,39,30,10,12,18,1,1,38,31,32,11,9,1,35,12,4,35,49,43,32,14,38,43,0,45,29,7,15,35,0,44,17,26,7,16,38,29,30,3,43,14,46,3,48,49,38,9,30,21,25,19,15,9,0,14,37,35,46,19,38,15,10,48,23,0,39,22,35,14,26,30,2,42,38,13,6,35,4,4,41,18,43,25,0,41,31,47,4,35,32,27,27,19,33,24,19,35,39,25,15,40,16,21,27,0,4,25,7,16,32,26,8,23,5,7,25,29,18,10,38,33,37,7,48,5,25,8,8,7,35,21,50,32,19,36,31,6,21,14,15,46,13,29,5,24,10,25,46,18,3,40,17,11,37,11,18,22,37,8,15,12,20,14,31,32,12,10,41,38,11,24,32,32,37,5,16,5,46,47,41,36,41,35,41,12,44,20,43,23,14,39,41,2,47,26,40,37,29,0,23,37,49,39,18,28,25,14,3,10,4,2,4,14,40,38,29,35,14,21,12,45,5,41,38,43,34,43,46,22,42,44,35,40,24,48,31,9,2,43,13,42,21,41,21,10,39,26,22,26,4,20,10,36,36,37,10,17,4,41,0,39,18,42,29,8,1,24,48,37,36,45,24,48,49,15,42,43,13,34,10,30,19,32,5,29,10,50,5,12,21,17,15,15,34,30,24,45,22,18,37,50,20,18,22,34,19,31,20,48,38,17,22,27,12,41,18,45,43,0,15,34,6,44,0,46,16,12,35,39,12,33,33,31,9,31,17,46,3,36,42,23,5,7,43,1,24,42,30,27,10,45,18,27,23,26,8,6,6,42,13,46,28,21,50,3,19,14,42,5,39,15,50,2,20,13,38,29,7,23,11,47,40,27,36,38,38,38,41,11,5,38,42,21,39,31,27,9,40,2,25,5,11,31,35,25,4,22,44,27,36,41,39,14,10,14,29,34,38,19,17,14,17,49,40,18,14,49,50,22,4,31,43,26,3,0,20,48,2,18,40,17,29,14,29,34,13,22,29,1,24,17,20,42,11,41,38,6,32,6,49,46,25,4,43,33,41,9,49,23,17,29,35,23,12,35,44,37,3,21,14,45,37,21,41,41,35,23,20,0,32,21,40,15,48,31,37,32,13,35,15,7,2,4,45,48,16,15,48,45,33,14,12,50,39,6,31,0,23,21,23,41,5,45,1,2,24,29,3,27,21,48,17,24,16,15,16,10,36,26,5,14,7,5,9,12,31,3,8,50,45,3,9,7,14,42,2,39,11,8,29,21,4,12,15,21,34,13,16,11,9,18,34,42,16,6,26,48,11,2,26,34,44,34,14,7,7,42,2,30,23,21,2,43,16,36,49,28,7,39,2,20,0,3,32,16,2,32,29,39,15,12,24,50,0,21,42,8,3,44,18,35,14,25,8,40,45,29,43,12,3,11,34,24,13,9,7,28,27,44,40,48,37,7,0,43,48,6,24,10,28,38,48,36,40,30,36,49,26,0,5,35,27,36,12,13,16,37,43,38,3,22,32,9,22,14,25,32,13,30,40,17,6,44,20,16,26,6,21,42,15,48,28,44,11,38,5,26,36,17,19,35,25,39,7,15,17,34,20,2,28,50,1,27,12,42,50,1,46,18,18,35,29,33,10,13,21,26,5,31,10,4,47,27,2,41,49,4,12,18,16,0,47,0,49,46,9,11,42,1,5,8,33,40,47,42,17,5,7,29,44,0,34,50,35,48,43,26,18,7,11,45,22,9,34,26,45,10,11,9,1,21,41,26,20,35,39,32,2,46,41,32,15,47,48,29,30,38,43,15,19,14,11,12,11,42,35,13,32,23,44,30,6,1,47,9,3,36,21,37,42,16,11,13,22,39,11,32,13,9,28,17,2,43,46,41,47,48,45,43,22,45,19,28,29,34,49,44,9,32,45,49,44,11,41,27,0,18,9,36,34,50,48,49,10,10,41,28,35,34,25,1,20,40,38,21,6,39,2,7,39,5,13,29,6,39,46,43,45,44,18,42,3,22,7,17,45,48,4,10,43,7,35,41,29,39,3,7,32,42,42,8,16,3,13,21,35,36,43,10,28,40,0,0,36,42,6,36,34,32,36,44,8,8,34,2,31,1,5,14,7,46,1,36,21,36,46,15,46,6,38,50,5,12,47,29,1,29,1,10,0,24,2,43,46,4,29,50,49,11,6,18,49,23,31,4,35,46,23,15,48,34,41,48,24,2,33,28,2,2,6,21,28,0,38,45,25,36,44,42,36,34,37,34,44,26,36,6,16,40,3,41,46,46,45,16,23,16,40,35,21,14,2,45,10,22,44,2,43,16,31,47,23,15,25,44,21,29,5,25,17,7,13,23,15,7,43,19,39,16,43,3,24,15,29,35,10,30,11,11,30,0,10,30,27,19,36,27,8,26,19,6,19,49,8,30,22,49,11,36,39,49,6,40,6,30,12,41,49,22,3,19,25,8,27,49,11,1,2,45,50,35,12,15,16,25,13,30,19,0,18,18,26,2,38,44,3,21,20,12,49,13,32,1,17,35,30,4,26,15,21,29,31,26,0,50,5,34,2,25,30,22,25,16,8,13,23,29,9,9,50,31,0,8,39,22,29,48,36,49,6,41,45,5,31,43,11,31,41,7,3,7,12,36,20,31,11,5,33,30,36,1,26,21,36,3,3,19,3,4,16,22,0,22,1,32,26,16,32,15,37,1,24,1,44,23,17,40,45,38,13,28,5,38,41,1,10,14,24,26,21,41,44,49,22,15,32,23,1,38,42,29,23,44,5,6,28,23,9,42,47,46,31,5,33,17,8,10,37,26,37,32,7,24,40,39,13,20,12,41,8,19,10,3,29,28,7,10,49,37,45,44,48,38,27,3,26,24,46,2,33,38,32,44,26,39,17,47,28,3,45,27,36,8,14,20,8,39,40,20,9,11,38,14,39,34,20,22,39,29,48,19,17,18,45,14,32,40,14,4,33,27,45,31,4,27,21,43,9,1,7,40,12,14,30,2,19,22,42,5,12,10,7,2,24,24,41,10,3,39,7,47,35,31,8,32,28,25,15,42,3,37,32,35,50,25,18,10,45,8,34,15,3,29,18,46,19,48,12,14,31,30,9,0,49,14,42,15,12,20,32,18,9,41,26,17,1,24,16,46,30,14,14,14,47,17,0,0,17,39,4,13,32,35,15,8,35,13,2,37,29,22,27,21,32,9,24,23,3,29,33,1,13,14,1,20,41,49,29,23,11,2,17,24,15,15,21,44,4,28,12,2,23,17,22,6,12,8,35,19,1,15,5,47,33,11,19,8,0,10,46,46,38,36,7,0,8,2,2,43,31,49,1,4,30,25,49,15,9,29,10,21,0,29,39,18,28,48,20,8,7,8,2,3,8,7,14,41,18,7,46,12,49,41,41,26,39,43,34,32,9,11,5,25,34,20,1,21,25,39,49,28,42,41,9,29,11,18,20,31,3,33,7,43,48,2,29,14,40,13,8,4,40,11,12,27,25,5,39,40,10,20,34,46,50,40,26,34,50,35,2,47,0,8,44,0,37,27,10,19,50,24,37,1,35,5,23,0,1,12,30,30,17,19,9,17,10,4,49,44,33,34,44,10,28,34,18,46,41,5,16,49,11,16,2,31,39,32,12,35,18,35,7,12,18,3,21,13,37,14,26,8,11,42,5,32,5,48,46,17,4,44,44,32,41,29,40,5,14,30,1,17,32,41,49,50,16,10,33,39,1,26,14,40,46,23,42,9,45,38,2,41,22,12,45,13,28,50,19,40,30,8,49,11,12,13,31,3,44,42,32,2,19,29,13,7,35,23,49,23,48,32,25,36,14,24,15,20,48,11,11,15,38,0,25,3,32,2,43,41,14,17,32,20,40,16,11,17,1,3,20,38,6,11,10,13,7,19,39,40,34,15,40,1,49,37,47,0,26,28,4,33,17,21,2,20,31,15,18,27,18,28,17,6,9), 78)
18
+ }
19
+
20
+ test("test5") {
21
+ assertEquals(Main.beautifulSplits(49,22,17,49,46,40,47,30,40,36,9,21,32,39,47,45,33,11,9,11,24,48,33,15,27,48,5,44,2,49,22,16,31,4,31,21,46,40,8,15,14,17,24,25,0,7,16,37,7,48,34,1,7,48,25,26,12,10,44,16,37,10,30,49,25,30,8,8,32,43,28,40,10,34,1,47,16,12,20,50,15,8,1,36,44,14,27,33,26,39,26,5,5,26,6,40,17,30,20,28,47,29,50,23,20,20,26,34,25,44,32,23,50,7,45,7,40,0,6,9,9,21,4,3,16,16,3,32,20,30,45,43,23,36,11,25,38,30,24,30,22,35,12,47,7,7,39,33,7,4,1,47,8,20,27,4,34,43,39,45,32,50,35,43,35,0,3,45,36,42,0,45,10,29,26,47,17,25,18,29,33,35,43,23,35,29,27,7,31,48,11,24,15,44,5,2,23,3,27,44,47,0,30,25,46,18,24,4,31,10,35,5,24,49,34,24,36,28,22,0,30,3,41,40,48,28,24,19,36,41,8,17,50,9,41,21,45,14,5,24,11,26,0,4,24,31,45,36,5,45,25,6,23,37,43,35,2,25,32,21,17,34,21,41,50,4,0,43,5,13,9,49,10,17,11,42,5,49,6,2,24,5,46,25,2,32,0,38,2,36,42,31,25,3,47,1,43,40,40,50,28,2,21,2,36,32,5,42,31,35,22,37,1,27,2,45,36,18,13,49,43,9,26,29,44,34,29,42,31,23,49,17,45,8,5,25,0,10,7,45,11,34,26,41,40,3,41,12,16,31,21,14,18,21,39,44,16,34,23,45,43,32,4,42,12,15,43,0,21,23,3,21,33,42,8,38,8,6,0,16,21,38,8,41,25,46,7,12,45,24,32,5,7,4,2,1,0,30,9,19,39,5,23,16,26,45,5,8,38,38,50,23,40,1,30,34,45,46,15,15,50,23,10,50,20,32,27,28,43,39,29,47,34,34,38,3,38,15,48,45,44,16,36,33,16,6,17,33,30,13,36,17,48,48,39,40,27,36,18,49,50,29,2,5,18,26,44,19,21,37,8,27,4,28,38,10,46,28,11,49,7,42,20,28,29,11,11,49,36,46,41,26,42,41,33,36,20,40,32,3,14,9,20,28,35,49,28,31,30,44,17,40,48,33,29,47,37,18,0,43,28,49,29,4,41,13,2,38,29,19,28,13,12,41,50,36,17,38,42,17,42,7,47,11,7,9,12,19,45,15,15,5,46,41,26,10,21,44,19,28,50,37,46,6,39,0,37,22,46,14,28,29,37,47,25,30,5,13,34,28,44,47,49,0,34,39,21,20,13,25,15,9,32,45,29,14,13,46,49,45,41,4,10,12,16,18,15,40,9,29,19,9,45,36,4,40,9,47,30,28,28,5,4,15,48,11,20,2,14,26,46,4,33,30,3,32,18,44,27,21,19,27,43,39,47,21,25,5,46,9,18,15,22,7,40,38,33,44,44,30,32,40,50,2,28,30,36,27,4,34,22,46,1,26,32,25,11,11,45,7,49,38,50,5,34,31,21,47,15,13,10,37,14,1,14,15,38,19,34,45,10,11,28,13,34,13,25,14,49,4,38,40,10,49,44,48,28,5,30,23,37,3,39,47,27,9,39,5,11,29,7,41,29,7,26,31,42,31,38,40,33,49,45,30,11,7,45,26,6,22,28,44,40,23,44,15,35,5,31,28,31,23,50,6,10,0,44,32,5,40,40,14,37,22,4,24,5,33,14,11,1,3,4,38,50,41,15,45,21,35,36,19,9,43,1,40,23,41,39,8,2,50,7,47,7,30,43,47,45,4,11,28,43,11,34,47,40,29,39,41,24,22,45,23,40,13,9,43,9,26,49,23,34,9,49,6,24,32,20,16,42,43,29,43,46,36,40,30,18,23,37,14,4,6,7,2,7,22,32,20,43,36,31,30,24,40,30,45,31,7,8,50,31,8,8,16,9,28,5,46,22,34,21,48,12,18,6,30,6,18,22,26,4,28,11,31,48,7,13,10,24,48,15,22,0,29,5,29,39,23,30,0,27,9,19,12,14,7,6,6,21,16,15,39,13,33,36,0,24,28,30,14,10,46,1,39,9,24,26,35,21,15,45,48,43,36,22,27,12,26,48,1,46,2,3,41,24,39,45,41,24,3,21,38,26,37,6,48,17,46,50,34,19,44,28,1,43,2,9,12,23,20,18,13,43,48,50,39,18,1,17,17,0,1,21,25,19,23,40,35,50,2,45,42,26,12,12,12,7,27,45,18,1,6,4,48,40,3,32,3,13,48,17,23,30,41,1,39,33,15,16,43,21,13,18,8,49,27,30,0,43,20,27,50,39,1,44,34,39,15,7,22,14,24,22,45,20,33,2,50,30,6,17,43,5,26,29,3,13,45,46,1,16,11,3,23,29,45,13,30,15,18,27,31,9,46,44,15,23,13,47,7,25,17,33,27,4,8,37,33,19,26,46,27,2,23,49,15,11,20,48,10,47,47,11,49,4,11,20,23,47,50,6,9,26,11,38,32,25,27,36,28,12,47,43,36,24,17,15,31,44,49,48,31,46,2,48,15,16,22,24,41,42,45,26,6,38,6,17,43,9,4,47,32,19,22,5,29,35,35,19,10,15,45,3,32,42,20,39,8,1,16,39,7,17,34,24,4,36,42,5,47,30,4,46,24,28,48,41,3,24,4,34,35,20,30,40,9,38,32,22,49,29,39,3,35,31,23,46,45,32,43,50,37,8,1,36,18,6,12,28,10,20,2,3,15,26,30,25,37,42,40,13,1,49,35,1,1,18,35,33,37,6,3,21,33,29,30,2,22,40,8,39,18,5,15,11,7,11,39,48,29,10,24,2,36,43,40,40,11,34,33,4,30,38,0,34,36,9,38,12,41,31,48,24,35,43,49,39,9,28,8,33,50,30,46,8,9,48,35,33,6,40,11,32,6,15,34,26,0,4,27,46,21,46,12,22,3,7,22,50,18,3,10,41,50,43,14,43,27,7,21,36,15,27,31,43,47,20,27,40,29,21,43,35,50,42,2,33,39,29,10,12,28,41,3,48,32,35,44,37,1,35,47,49,0,34,23,26,18,31,27,16,47,25,24,25,4,14,16,38,17,29,33,24,28,13,26,14,38,33,3,28,12,14,35,10,19,2,45,13,49,5,34,37,41,21,21,14,5,42,46,37,43,17,35,21,7,11,2,23,21,5,24,46,28,0,7,43,3,49,10,5,4,36,39,11,38,28,45,33,3,0,24,18,22,33,20,32,10,0,25,0,16,22,26,50,29,7,34,48,20,36,11,2,50,42,29,49,11,1,45,13,4,13,0,38,42,32,36,41,33,48,40,27,23,21,6,41,46,49,11,21,5,41,45,5,33,25,32,35,26,32,34,3,6,5,39,29,11,35,2,34,25,0,2,2,9,40,16,3,37,37,46,48,30,30,39,15,24,34,3,41,36,43,10,25,18,34,2,8,48,37,45,25,0,43,12,10,2,12,47,7,17,2,8,12,41,8,5,45,11,0,41,7,14,31,38,19,13,20,7,6,29,26,41,7,10,40,16,33,16,26,29,48,41,43,2,7,45,24,49,30,33,29,45,48,12,6,22,41,45,38,7,6,41,13,32,29,49,38,2,32,5,43,11,30,26,11,23,44,15,27,42,38,8,15,47,6,3,21,38,38,2,30,27,47,30,25,37,33,2,13,40,43,26,29,28,50,25,31,22,14,22,29,38,45,49,6,14,38,5,12,27,48,13,14,9,1,41,18,15,37,45,18,6,34,50,17,3,6,40,9,48,6,40,50,19,7,7,17,17,0,11,14,10,50,45,24,37,22,19,47,33,50,39,32,29,17,1,27,8,32,4,17,11,33,1,35,16,43,49,12,50,46,7,47,11,4,17,4,47,4,16,17,4,19,34,23,28,30,3,36,47,44,44,31,29,43,7,5,45,13,22,5,31,12,24,4,14,50,26,41,16,43,40,0,17,0,28,27,40,1,39,24,15,29,32,21,4,41,6,23,10,35,11,16,36,43,0,16,29,37,28,26,36,25,2,16,31,41,30,42,12,8,28,35,44,43,44,14,36,31,29,0,21,25,34,22,22,2,49,4,13,19,3,22,20,38,11,44,41,39,24,31,18,12,25,8,37,23,22,44,26,37,12,36,18,9,0,21,26,21,50,5,7,46,13,21,48,18,47,6,29,39,26,26,22,24,50,37,11,17,37,21,17,42,27,10,42,1,49,33,35,22,17,33,14,16,22,19,40,20,44,0,38,6,31,23,32,40,8,13,8,44,44,1,44,35,25,4,25,11,27,11,23,6,44,45,17,25,27,24,16,41,16,13,6,20,28,25,25,12,48,40,14,45,17,26,41,5,47,41,32,44,22,0,32,38,48,42,8,26,47,48,1,36,36,25,38,29,21,40,19,18,2,0,11,21,25,22,24,5,45,24,34,48,44,12,7,38,2,18,17,25,4,33,8,37,49,44,0,4,2,18,32,10,23,35,3,41,9,15,24,15,47,29,35,24,28,7,34,31,24,46,45,27,19,17,32,25,47,31,33,33,29,49,26,12,41,45,50,45,42,2,28,7,4,14,2,10,49,3,37,35,4,17,42,31,41,33,37,38,15,33,15,4,47,16,31,42,45,38,32,1,20,10,17,40,18,45,31,40,15,8,25,21,20,39,32,5,4,34,22,29,44,6,32,32,8,50,6,39,50,43,22,11,39,32,27,12,24,19,20,0,12,4,35,8,27,20,2,48,40,15,36,3,26,23,32,6,35,40,4,24,41,34,19,39,42,7,0,23,32,43,37,5,28,24,35,32,37,1,9,25,12,21,18,17,25,42,48,37,39,40,14,30,47,26,42,27,8,50,38,33,32,33,43,28,33,6,29,6,49,2,18,23,2,41,47,3,49,19,26,23,46,50,4,39,23,21,31,28,18,3,46,5,32,23,17,30,31,32,18,49,20,47,20,31,28,39,50,50,42,24,32,37,43,6,15,20,29,27,16,50,40,36,24,12,40,39,50,3,16,37,31,38,19,43,10,7,50,5,21,3,15,17,12,2,46,21,4,42,38,20,38,42,49,48,9,45,19,9,38,47,21,37,46,5,6,45,45,20,19,43,28,25,43,0,34,39,6,16,28,17,9,6,34,22,5,10,42,44,16,28,5,27,5,18,23,2,31,17,45,7,48,23,27,33,16,22,6,17,17,31,45,28,41,24,20,26,18,33,10,15,26,13,8,8,11,20,46,47,34,35,5,44,2,32,20,26,33,10,0,31,12,11,50,49,7,14,39,32,5,1,46,16,2,36,0,7,47,7,20,32,31,33,41,10,32,36,22,11,48,31,42,1,20,22,9,25,20,9,43,6,39,10,42,46,19,6,27,26,32,50,10,4,24,28,16,0,15,30,30,29,14,17,9,8,31,37,20,11,34,4,3,7,35,32,40,22,14,4,6,2,21,12,10,47,8,8,46,20,37,25,39,46,10,4,7,30,44,5,11,8,33,25,28,44,27,49,23,33,18,9,22,11,37,39,37,32,47,30,0,45,17,19,39,14,15,20,9,17,9,13,1,38,49,37,44,18,6,20,1,33,23,18,24,21,30,47,45,12,6,7,45,41,4,13,29,28,36,9,46,4,25,13,13,28,8,44,47,38,12,4,46,31,38,18,19,36,23,6,43,41,34,35,29,10,41,15,13,23,24,27,29,15,4,50,3,22,45,25,20,6,14,24,50,43,23,35,46,19,14,37,12,30,42,8,49,3,33,18,29,48,2,5,39,42,48,41,5,46,32,35,15,21,39,12,49,27,44,6,8,23,2,10,42,48,2,7,24,15,32,37,33,39,32,27,39,19,21,23,39,12,26,9,4,44,25,23,7,33,3,30,45,11,17,19,16,32,30,10,31,42,18,42,28,44,33,14,33,50,32,16,18,42,32,6,6,42,34,25,32,44,9,3,28,13,25,11,50,19,47,11,24,40,20,39,28,24,35,8,24,4,48,50,22,8,47,17,34,29,11,6,34,34,27,0,38,1,7,26,13,41,45,6,10,5,5,30,46,9,50,32,27,30,3,41,13,15,2,35,5,13,26,6,6,37,16,32,37,20,36,9,41,49,32,44,3,26,24,38,1,20,22,20,20,3,12,0,39,21,50,29,14,48,7,8,40,20,19,34,10,48,40,50,1,1,47,28,34,35,34,18,36,3,9,38,36,13,17,14,17,36,10,43,22,10,32,44,6,30,5,10,1,8,15,19,30,41,5,6,45,20,50,10,14,29,22,20,29,26,42,14,1,27,15,28,23,14,26,27,36,10,49,12,29,42,47,47,21,18,41,27,12,33,43,2,27,25,3,29,36,11,9,25,26,48,43,41,31,23,39,4,42,36,0,24,33,27,37,19,0,22,31,32,42,5,39,32,18,15,21,41,44,35,16,26,33,11,11,42,38,14,2,5,1,48,9,50,38,16,24,16,18,32,15,22,13,18,33,22,12,35,49,20,37,27,16,41,27,39,7,22,37,36,23,9,37,25,9,32,15,47,46,43,7,39,25,1,35,1,34,2,49,16,29,7,20,35,20,50,22,13,46,49,46,30,5,49,3,23,10,4,28,49,0,18,27,42,18,22,19,13,39,45,43,10,20,10,5,33,37,10,34,44,5,38,2,32,33,31,50,43,42,45,48,9,28,5,33,31,2,17,2,38,9,34,19,18,7,11,50,31,6,19,2,28,49,13,4,11,16,25,0,5,7,12,5,34,26,34,35,13,20,24,16,31,43,25,23,38,3,14,20,28,22,48,12,39,50,42,33,14,6,4,16,22,5,15,22,13,49,31,14,23,18,36,36,46,18,5,33,2,16,10,35,8,35,36,14,27,35,36,47,17,17,40,24,47,40,49,27,3,49,8,35,39,12,22,19,44,26,31,14,24,15,50,47,9,6,33,39,6,43,13,9,18,25,35,19,13,49,15,2,20,41,45,24,8,17,6,26,27,4,47,32,47,10,1,2,2,26,17,42,43,38,15,45,39,20,46,29,7,0,46,37,18,7,32,35,20,30,27,26,25,34,3,28,20,24,42,4,26,28,40,0,47,43,19,12,48,6,18,11,37,50,18,33,15,42,10,9,18,16,12,29,7,19,12,42,9,16,22,10,5,36,24,1,39,19,12,0,36,41,28,32,34,17,8,40,48,31,40,10,35,21,43,46,22,0,32,13,40,28,22,23,20,25,29,13,26,4,28,47,17,10,26,37,11,31,18,35,31,29,45,45,30,3,30,8,13,42,47,7,20,31,11,1,29,46,29,29,42,2,31,10,2,22,48,3,15,47,2,26,49,31,39,42,30,14,47,49,3,47,26,7,19,36,37,10,24,23,13,15,45,6,50,11,35,40,0,18,38,34,45,34,9,39,22,7,45,12,15,27,34,25,50,25,11,38,17,3,8,43,43,46,38,31,24,34,30,10,14,16,13,47,3,16,11,20,30,16,10,16,0,36,48,12,22,12,31,11,26,17,6,38,34,11,6,40,38,28,43,45,37,18,4,32,28,25,6,43,29,8,43,3,19,21,20,0,18,33,24,35,28,11,15,12,6,50,3,12,2,7,24,17,15,14,30,5,40,20,6,39,23,47,1,48,46,1,17,39,6,24,47,50,2,19,28,27,37,19,22,7,18,27,34,48,23,28,28,15,2,2,23,38,44,11,29,31,6,21,24,1,1,14,48,41,24,38,11,31,32,25,11,10,42,9,46,27,30,24,19,34,12,30,36,7,6,35,10,12,39,42,27,6,42,12,40,17,42,49,19,44,2,25,41,23,48,31,42,45,27,9,20,45,47,18,19,48,50,41,13,18,10,25,42,21,25,8,19,37,49,12,24,28,9,17,40,40,23,34,11,8,20,38,40,34,5,37,28,49,15,50,34,38,25,37,12,28,1,29,19,0,16,0,3,37,21,19,49,4,46,25,35,45,43,12,24,2,4,9,15,25,25,25,1,38,12,38,46,33,40,36,39,9,48,29,50,4,21,31,26,7,29,40,33,35,38,33,31,33,23,40,2,2,43,48,34,20,38,34,43,34,45,1,11,11,48,17,26,17,42,43,2,33,23,36,31,1,8,11,36,48,25,13,9,39,3,23,46,46,1,17,40,34,41,22,3,8,19,25,16,5,24,33,1,34,7,8,26,15,30,7,3,9,41,37,9,12,18,0,43,22,50,19,1,35,34,18,27,47,19,37,43,13,12,41,25,26,6,2,23,4,24,44,16,13,7,11,5,50,5,18,34,4,32,16,25,42,30,23,17,11,45,33,8,12,18,28,15,16,25,37,6,21,25,3,37,39,39,9,44,35,44,37,11,20,35,19,33,1,25,36,45,12,12,22,13,13,6,38,21,44,38,36,20,33,16,6,22,10,20,10,39,47,40,18,5,23,4,49,19,24,48,43,41,43,42,13,38,26,13,20,49,31,11,21,10,38,12,12,30,12,12,17,5,7,4,1,16,6,8,12,46,47,8,47,28,39,28,36,47,28,17,12,38,8,41,43,18,45,22,8,47,31,44,32,14,37,43,44,24,16,19,19,46,15,40,28,0,40,36,25,47,35,15,12,46,38,16,16,35,0,39,0,1,47,43,33,3,11,44,22,9,36,42,27,16,28,43,25,31,14,47,13,16,36,8,41,30,24,10,33,45,24,4,19,36,45,47,30,28,36,45,44,5,30,4,12,42,10,0,29,20,11,50,23,4,17,23,24,2,32,48,15,36,14,5,47,31,33,36,17,20,21,21,40,34,20,50,49,24,23,18,19,8,11,37,24,15,44,2,35,17,35,5,34,3,46,13,36,17,9,21,18,13,4,38,45,23,28,15,0,35,15,49,10,4,34,33,45,5,28,35,0,32,24,36,3,6,45,41,4,15,22,24,50,48,3,10,35,45,14,14,11,8,5,4,41,16,0,36,18,34,23,24,2,9,33,17,4,12,16,36,45,8,23,15,44,50,39,36,26,42,11,26,29,0,45,26,35,41,39,3,10,6,41,27,0,27,12,4,27,11,49,38,19,21,39,27,8,26,48,3,22,42,46,13,48,2,36,2,45,10,45,24,43,29,21,2,2,9,8,12,3,29,16,16,44,19,48,36,17,39,22,44,49,13,41,43,28,26,1,39,21,4,41,29,22,36,19,25,35,19,49,44,36,35,5,14,48,40,5,28,41,37,9,42,6,39,44,10,0,5,16,18,28,40,30,4,32,31,18,43,28,34,25,18,16,40,30,0,28,43,12,43,48,32,9,31,33,12,29,18,23,7,44,36,6,47,16,10,38,17,9,11,23,23,29,44,10,39,19,48,7,50,10,2,10,11,22,1,19,17,45,24,1,49,14,40,39,42,21,14,45,22,47,49,4,34,32,39,7,27,4,16,34,27,8,49,41,22,33,28,50,45,16,47,36,46,14,25,6,9,19,5,39,2,49,29,42,28,49,29,7,25,23,33,38,38,15,50,1,1,13,9,39,13,16,8,24,1,14,35,25,50,24,35,40,29,11,14,49,45,37,48,27,22,28,30,32,5,26,42,33,24,3,6,22,5,44,0,6,28,48,43,38,5,11,30,2,10,28,3,48,11,10,16,12,24,8,28,46,34,49,16,4,3,2,34,8,31,10,22,29,34,35,25,47,16,4,13,4,41,18,49,34,23,21,23,45,13,30,3,35,45,3,41,23,24,14,44,31,30,50,10,29,16,12,9,6,9,2,9,6,29,42,38,5,20,15,13,2,23,0,10,3,39,16,44,14,34,0,15,33,11,50,9,11,31,9,3,29,1,18,48,37,10,15,25,49,34,33,0,50,39,32,23,19,33,2,30,1,37,21,41,31,46,17,27,46,39,44,5,11,3,22,34,24,9,23,25,21,31,29,3,42,28,22,27,46,35,10,32,25,36,21,16,24,32,32,15,36,42,14,7,39,11,33,39,36,2,36,34,14,29,8,2,35,23,34,26,41,22,17,34,47,19,28,41,46,29,25,24,33,37,2,42,3,23,1,22,17,12,14,10,13,40,2,1,48,23,24,44,42,34,22,3,29,27,40,43,36,35,35,26,44,22,16,27,30,21,34,31,0,21,42,44,10,10,29,50,34,33,41,14,33,36,32,39,13,23,20,18,5,43,14,14,27,43,34,0,26,14,24,2,12,29,28,48,3,23,47,27,0,29,39,31,26,48,29,41,40,24,50,43,20,12,8,42,22,19,8,40,44,44,20,22,44,3,33,36,17,1,2,39,7,37,16,4,41,5,42,7,30,25,2,45,41,33,9,50,25,14,50,5,15,46,40,39,0,40,45,39,11,47,41,35,15,0,11,3,26,21,19,35,21,13,1,18,26,22,15,19,2,38,32,13,30,8,24,42,13,22,27,49,43,4,32,31,21,23,13,8,14,28,19,1,6,33,21,33,14,50,0,32,34,32,36,46,30,43,24,18,3,31,24,46,2,28,11,48,22,20,5,11,19,12,1,19,22,40,1,21,4,36,39,43,18,32,47,32,40,6,12,11,44,30,1,22,5,45,27,36,30,6,7,41,42,36,27,31,2,44,38,4,49,37,36,40,22,23,5,16,39,42,20,23,20,50,0,7,39,36,25,46,49,12,8,15,27,50,19,9,12,22,47,9,15,22,34,22,26,26,28,34,6,18,49,12,3,31,36,40,10,47,23,36,35,21,4,3,13,43,11,50,44,4,13,31,45,50,43,24,48,44,5,1,9,21,35,15,30,28,29,25,13,47,49,48,0,45,25,45,25,8,38,27,35,50,38,21,28,48,28,15,50,0,5,13,0,12,39,36,37,18,25,32,16,33,17,24,31,0,2,43,33,30,9,2,50,30,33,24,0,12,20,29,8,41,3,10,23,13,28,22,3,41,43,7,19,41,0,36,18,45,23,36,22,42,50,49,18,33,41,14,20,16), 92)
22
+ }
23
+
24
+ test("test6") {
25
+ assertEquals(Main.beautifulSplits(18,15,10,6,2,27,15,27,18,31,48,2,42,35,9,46,24,8,16,50,29,39,8,11,11,37,27,36,20,10,22,40,22,49,12,49,46,0,42,2,46,4,16,4,19,37,36,4,25,12,38,42,15,42,34,27,18,15,10,25,33,20,50,39,21,5,26,28,1,32,49,5,27,37,18,40,47,9,24,43,48,48,10,4,25,0,33,45,45,36,36,27,20,10,26,34,3,47,2,4,19,25,9,45,40,43,22,2,13,8,25,44,5,5,43,31,26,0,50,18,1,1,41,50,4,44,0,19,32,26,19,50,16,11,49,37,27,7,48,40,19,48,5,1,37,19,35,7,45,5,19,50,39,32,35,44,48,9,6,33,40,31,3,0,17,37,26,16,29,2,7,26,48,5,25,5,28,50,38,28,10,50,45,28,22,13,38,29,32,29,29,33,8,31,5,29,39,33,3,17,22,16,34,30,40,44,50,4,41,9,41,38,39,50,10,17,14,50,47,30,41,40,1,32,1,37,28,37,8,16,5,12,0,0,32,27,43,44,42,9,31,9,8,12,46,34,37,32,34,47,24,26,16,22,43,14,4,13,13,7,33,34,21,22,12,7,30,19,25,23,2,39,48,9,42,12,33,3,16,33,39,1,43,12,16,18,40,34,50,6,17,37,38,18,35,46,34,24,40,1,44,20,29,45,46,33,12,44,4,31,18,38,21,24,9,44,39,18,4,34,18,40,28,15,47,32,43,43,15,35,27,49,16,23,15,40,16,35,2,18,44,46,42,41,11,24,28,26,6,26,27,35,18,18,39,30,5,6,27,6,24,9,35,20,2,3,4,14,34,38,40,24,36,7,23,18,20,49,33,44,0,47,1,7,8,14,31,34,23,42,11,21,38,43,41,2,24,32,18,49,39,46,5,6,11,3,45,18,6,36,40,29,36,3,41,2,34,28,36,50,23,10,41,45,40,33,40,33,6,5,1,47,38,20,24,50,30,5,14,12,46,42,45,28,39,13,25,2,28,40,25,25,9,45,11,45,27,40,5,3,34,20,30,32,8,31,49,34,14,25,9,32,16,6,26,32,30,2,29,34,44,18,37,31,0,1,15,40,5,0,38,14,4,15,39,25,40,32,16,5,2,10,2,20,35,11,47,41,11,6,23,15,36,50,36,29,16,48,16,27,1,33,35,42,17,21,28,34,27,36,44,18,29,17,43,19,27,34,43,7,11,2,25,40,24,39,1,46,2,32,4,8,15,37,32,11,13,8,18,32,12,50,7,24,33,6,12,32,15,14,42,9,49,24,19,21,13,43,33,18,32,32,6,38,49,37,6,34,24,49,10,43,13,8,50,44,10,4,39,1,41,8,44,23,4,39,42,15,41,5,35,15,30,18,31,22,41,30,3,25,0,8,34,36,8,3,46,42,46,43,38,11,19,21,5,21,43,32,2,38,49,13,27,36,28,46,2,37,49,26,8,43,48,43,10,22,23,25,29,22,7,45,17,35,39,20,50,26,2,6,37,48,10,8,35,13,38,5,10,40,35,21,41,3,8,42,47,45,24,48,48,47,47,27,23,2,13,29,2,43,17,41,11,38,37,41,42,18,15,12,40,23,20,27,12,49,45,47,0,3,48,28,2,32,14,42,34,34,23,35,24,14,20,24,40,14,22,11,1,19,38,0,9,28,47,18,28,17,3,22,9,49,14,5,4,0,16,49,3,12,7,34,24,34,50,11,33,29,11,35,8,5,1,41,42,0,37,3,42,10,15,24,44,39,41,35,10,21,34,20,38,21,26,25,42,16,12,10,41,3,42,5,29,2,44,9,22,41,11,27,3,22,37,16,41,28,16,17,43,44,14,25,38,25,22,17,40,50,4,44,2,21,36,28,9,44,22,39,36,46,33,43,1,16,21,35,27,34,34,46,45,10,48,32,35,5,4,30,20,23,38,8,39,1,35,38,18,3,11,42,50,19,10,26,22,41,48,9,26,7,28,29,9,41,6,3,49,0,33,20,45,46,49,48,45,5,16,2,44,24,36,38,41,11,32,11,49,44,5,22,17,31,12,23,20,6,23,7,29,7,5,25,49,41,42,3,49,38,25,42,48,11,49,11,2,34,39,7,6,47,44,35,19,47,26,21,13,19,26,0,16,9,5,25,27,23,4,29,30,29,40,42,45,42,37,0,0,32,5,7,23,30,20,36,46,30,32,34,33,45,18,38,45,29,31,28,15,1,20,27,27,1,48,50,31,26,12,18,41,11,27,15,18,8,6,45,41,0,17,25,9,43,42,9,4,18,35,50,12,29,35,14,41,25,25,33,27,22,34,13,44,38,46,36,47,12,20,2,29,43,46,39,19,24,20,25,48,2,12,25,8,13,17,10,31,49,7,39,12,31,29,1,19,36,0,43,38,19,4,33,3,4,21,45,45,18,27,22,7,23,40,35,25,41,32,41,29,3,12,29,22,43,11,30,31,20,24,21,41,36,48,16,14,39,13,10,23,17,44,50,1,16,2,12,15,8,8,49,23,2,50,50,49,32,48,18,39,15,7,37,11,24,2,47,18,36,25,33,15,23,11,8,45,49,43,23,48,21,36,20,30,40,50,50,0,20,20,20,32,37,34,32,47,13,28,3,41,24,45,8,25,19,2,21,30,6,42,50,40,46,8,31,28,25,40,0,23,34,15,46,4,25,17,23,37,4,15,0,1,42,29,24,32,32,15,48,49,7,3,30,36,39,41,45,13,32,2,23,19,39,22,43,36,1,27,32,6,19,24,49,31,17,39,27,30,2,39,42,42,7,26,12,22,15,32,15,14,32,15,25,1,45,16,45,33,47,13,39,32,35,13,5,31,34,14,4,6,15,43,24,50,23,28,14,1,48,40,35,42,16,36,22,43,0,29,7,5,0,7,50,28,31,37,14,18,9,17,17,47,19,45,33,47,36,15,2,30,28,50,26,3,27,12,29,29,7,38,49,7,9,11,15,41,38,38,34,36,17,41,15,46,1,44,10,48,28,45,32,19,14,7,28,2,26,41,7,10,24,0,50,3,17,47,37,14,20,39,48,8,34,47,14,14,40,23,23,46,1,18,48,15,39,0,21,38,32,3,38,34,0,5,24,23,9,16,2,14,11,6,47,25,14,32,4,25,17,31,39,1,7,44,1,10,14,13,5,7,15,34,22,42,45,10,42,4,28,42,1,1,45,14,40,14,46,11,38,10,31,42,0,8,35,10,34,17,11,8,16,19,20,42,43,22,31,18,27,32,26,46,31,11,49,15,35,21,32,22,29,13,20,16,34,39,34,11,49,41,12,8,45,40,41,34,31,27,24,33,40,31,24,35,12,4,13,27,43,42,45,11,0,41,27,38,43,15,2,9,48,22,35,13,38,29,50,29,43,17,47,37,35,48,50,38,9,10,45,39,46,48,30,12,26,9,33,26,27,50,11,12,0,0,8,17,50,1,24,21,2,50,36,17,26,48,1,43,14,18,48,48,32,8,45,9,13,37,43,10,41,38,34,46,8,4,44,12,37,41,4,35,21,7,28,44,9,33,22,13,20,4,2,20,23,21,35,45,44,29,3,48,18,45,31,30,9,43,13,42,49,40,1,18,1,44,29,24,6,36,30,12,47,38,36,1,46,3,37,37,15,12,24,34,39,30,50,30,28,34,0,38,5,29,37,0,5,38,29,41,24,50,33,42,46,35,7,33,47,15,21,5,17,4,45,2,4,28,31,14,27,36,36,12,31,33,48,6,39,46,36,9,45,10,31,21,38,44,48,38,21,22,44,7,5,37,25,10,3,9,32,30,12,1,18,30,48,10,23,36,13,2,48,49,35,33,7,21,48,34,6,44,2,40,48,35,48,47,7,31,45,35,50,22,45,36,33,28,15,10,4,7,4,32,23,47,19,4,24,12,20,1,36,2,28,30,37,20,10,41,3,0,17,5,31,29,13,18,43,17,15,25,32,1,19,34,49,28,38,30,36,33,15,43,28,9,48,30,4,32,48,13,43,28,29,24,1,41,48,4,40,32,0,42,45,50,2,16,40,12,41,16,15,6,49,39,34,12,17,10,32,18,41,16,28,21,33,9,49,33,41,30,4,35,24,9,23,4,34,3,31,40,36,6,4,40,33,26,35,18,4,8,19,23,38,44,21,35,39,14,2,7,7,2,20,5,50,30,5,48,35,17,22,26,27,46,27,16,5,7,20,40,14,36,27,28,38,12,4,27,21,46,18,47,11,49,32,9,49,8,26,22,8,29,39,30,49,30,4,2,23,9,31,7,48,6,17,13,11,9,17,31,37,11,10,35,20,30,27,38,50,2,9,35,45,39,45,30,38,50,22,43,30,29,4,41,28,33,46,33,17,8,15,2,43,4,19,28,33,19,9,38,37,47,47,49,5,18,38,19,36,30,11,40,33,20,2,34,47,44,47,12,12,39,30,12,37,35,28,41,48,26,33,8,18,38,5,10,19,42,23,45,48,36,43,7,44,22,36,45,40,48,7,5,25,50,39,36,30,39,35,9,42,5,22,27,3,18,47,10,1,41,8,30,39,12,22,3,36,3,32,49,49,38,44,25,0,48,23,46,17,22), 43)
26
+ }
27
+
28
+ test("test7") {
29
+ assertEquals(Main.beautifulSplits(47,45,25,21,6,9,26,23,0,28,2,4,14,12,49,30,29,47,5,44,6,23,9,29,21,32,18,43,25,17,16,33,22,49,48,36,35,47,23,37,0,0,16,1,2,17,13,2,3,24,34,17,11,48,20,42,47,47,46,34,43,8,21,12,21,2,11,6,20,27,14,39,23,2,40,24,46,21,25,20,13,33,6,2,10,39,2,21,35,39,20,18,50,15,4,15,7,14,40,45,25,31,13,13,1,48,20,46,23,46,1,30,47,25,50,11,47,34,40,9,34,42,0,46,17,4,31,42,4,47,15,9,37,31,45,35,34,13,10,19,38,50,7,2,37,14,23,5,29,0,15,8,7,37,37,11,20,23,18,40,43,13,7,48,32,36,47,37,49,6,20,15,22,38,40,50,22,22,0,18,44,3,4,40,37,31,18,42,0,4,3,33,18,12,10,18,18,5,4,6,40,22,43,42,28,22,46,46,29,16,36,1,20,25,8,2,36,40,1,43,24,12,49,1,23,26,20,31,22,36,35,24,32,38,0,12,36,3,31,21,19,12,31,45,17,43,10,3,3,8,37,42,11,3,34,11,32,22,23,34,36,23,17,38,26,9,49,19,11,33,37,46,39,24,28,5,49,39,21,47,12,15,20,15,50,14,5,5,31,49,37,35,15,20,40,33,37,6,12,4,46,22,27,16,48,2,32,43,39,22,35,9,8,14,27,15,28,33,7,46,46,28,28,45,10,27,19,15,34,42,10,4,26,40,16,14,3,13,13,13,31,36,43,28,35,32,24,41,17,40,43,3,44,50,17,29,41,37,49,42,9,24,36,31,39,0,48,42,21,16,49,20,15,37,21,42,48,47,36,41,14,3,18,48,24,9,0,38,43,32,12,2,25,37,2,8,5,29,3,3,29,11,19,49,36,7,1,45,48,28,42,23,13,11,14,42,4,0,4,22,33,26,9,33,3,42,30,4,28,2,23,32,3,23,26,46,26,1,9,22,48,28,4,31,26,44,13,18,12,11,15,49,9,24,23,42,23,42,7,46,37,0,33,26,40,33,49,3,28,27,49,35,11,38,43,26,13,23,17,14,10,31,42,33,12,15,14,15,8,47,12,13,50,35,31,35,38,18,12,47,36,29,6,21,26,9,15,36,18,12,18,10,29,4,23,16,28,0,30,32,7,40,39,37,49,24,44,19,37,41,15,13,18,50,48,35,48,5,8,5,30,47,30,46,8,38,17,6,4,48,41,26,13,28,47,16,22,31,1,32,37,0,46,12,33,46,23,25,37,40,28,16,43,47,25,42,14,17,7,24,31,4,31,8,13,2,8,4,16,35,37,30,10,40,24,30,41,11,14,45,21,12,5,23,8,47,44,11,23,40,10,40,42,19,15,29,30,47,9,26,26,13,2,9,36,15,22,30,41,45,33,35,45,22,0,46,45,40,33,6,19,11,17,40,46,44,48,47,47,19,45,14,33,15,24,20,13,10,12,7,28,13,2,32,36,20,7,24,1,17,0,50,22,34,18,40,41,46,40,31,39,36,4,30,28,0,29,10,7,48,2,13,50,23,45,3,50,22,40,46,3,32,36,28,39,50,25,35,38,50,1,47,26,31,36,40,29,10,4,5,28,1,2,18,7,39,30,50,48,23,16,1,1,48,29,43,44,30,25,26,27,34,2,4,19,3,32,37,31,16,20,49,50,5,13,24,1,28,6,10,8,23,25,4,28,44,27,18,38,12,41,25,48,22,29,41,23,27,47,3,34,33,21,3,8,10,32,28,4,13,41,3,14,41,33,34,13,47,49,11,11,27,13,46,24,8,35,36,13,22,44,20,27,7,31,37,48,39,6,33,8,28,14,28,24,27,25,8,42,43,14,23,20,22,15,10,7,49,3,46,9,9,3,30,8,14,45,41,47,43,2,48,23,3,1,34,18,41,19,12,32,28,35,1,33,17,3,36,43,9,2,32,11,38,8,45,9,40,13,1,16,33,44,4,26,46,28,38,1,14,17,42,11,44,43,26,24,39,34,28,14,18,22,18,37,29,27,43,43,37,30,9,46,22,20,35,31,40,33,14,17,8,19,16,25,41,27,1,18,25,21,6,25,38,28,37,40,10,50,41,18,22,14,25,25,42,25,8,26,2,25,40,36,22,45,19,18,30,2,40,28,15,41,11,30,1,32,31,43,45,48,49,36,44,14,38,35,49,29,27,43,25,49,8,3,14,48,3,20,37,36,5,16,15,4,46,45,9,37,39,33,7,26,47,45,14,50,47,15,48,13,1,14,13,41,43,3,2,47,24,4,13,40,27,10,16,32,25,46,20,13,18,46,9,14,3,22,26,13,18,8,3,40,48,13,30,15,17,29,5,44,48,13,18,31,20,27,32,8,30,42,45,8,50,12,21,48,43,24,17,4,8,7,4,50,4,8,7,42,1,13,46,3,38,7,24,47,36,26,14,16,16,5,42,37,5,6,45,34,15,0,21,8,11,37,17,40,48,19,34,23,9,11,8,48,49,26,9,23,16,0,42,13,40,15,40,11,13,0,5,48,27,40,27,7,15,31,43,29,38,18,7,23,18,27,25,43,5,27,15,44,47,42,28,23,6,5,33,39,48,29,22,45,46,28,47,33,3,14,2,32,27,9,31,44,2,27,47,36,32,19,11,27,11,23,39,43,8,43,31,35,27,34,48,22,11,36,33,42,22,2,39,1,15,9,17,44,32,29,17,29,13,31,13,12,45,38,25,0,22,6,25,36,6,32,38,19,9,28,39,35,35,0,34,4,4,36,37,4,5,43,43,37,25,11,5,17,45,7,37,8,10,17,34,47,22,45,29,22,40,6,7,27,12,27,21,26,32,0,11,20,15,29,6,14,0,26,13,23,1,1,20,14,27,14,12,27,31,15,38,5,11,21,26,36,33,29,10,25,25,44,44,33,15,49,45,22,37,25,48,5,38,48,42,38,13,40,19,15,14,45,9,22,25,39,6,7,6,31,24,25,41,19,41,6,48,33,33,32,18,20,21,10,10,2,45,8,44,24,40,2,43,10,50,50,33,34,25,0,23,15,10,7,17,6,10,42,1,3,27,42,6,23,41,42,3,2,15,7,23,41,9,7,18,11,11,41,48,12,43,41,14,24,42,0,50,20,19,50,9,10,4,46,46,23,29,27,11,0,22,26,43,21,26,36,35,7,6,46,37,43,43,46,36,5,12,16,39,4,35,23,35,3,22,44,34,38,13,25,46,4,36,21,29,6,16,49,29,22,12,23,3,7,3,23,17,25,38,49,26,21,48,34,50,13,38,5,26,33,45,47,33,2,18,33,3,19,48,37,2,6,34,21,35,36,24,41,35,18,4,16,42,45,24,47,48,44,28,18,13,18,13,46,1,1,1,3,15,33,6,31,49,5,8,24,35,22,22,45,18,11,36,2,10,29,3,7,8,19,5,8,34,44,28,33,41,38,0,33,8,37,35,2,25,24,4,49,25,3,1,12,3,49,44,32,3,9,26,41,2,50,47,44,0,34,46,8,28,7,8,14,19,30,8,21,19,47,6,16,32,38,15,2,39,44,13,33,36,30,9,42,17,35,42,22,36,42,37,0,40,31,33,18,22,23,20,50,22,6,9,33,7,24,40,25,2,35,0,45,12,25,14,44,4,9,38,24,21,7,47,49,27,16,33,8,42,4,17,37,41,5,25,39,13,7,23,12,23,39,29,38,2,21,15,31,43,21,5,35,45,2,50,10,0,30,12,4,32,34,22,25,13,32,31,24,1,47,4,31,33,26,29,23,12,1,23,45,41,13,44,0,14,30,32,44,29,3,10,29,14,31,14,44,16,47,36,45,30,46,41,20,3,14,11,20,5,27,6,34,49,3,13,8,19,7,33,24,45,38,29,19,16,2,27,42,36,30,17,24,28,5,46,34,6,46,28,24,32,41,21,26,1,18,12,47,45,9,11,35,21,35,5,16,39,9,24,36,35,38,14,15,24,34,47,14,46,18,43,23,30,48,48,30,10,49,45,22,15,41,27,9,8,40,3,0,6,5,40,37,4,32,2,21,4,47,9,38,26,46,39,32,30,42,17,39,34,22,22,9,26,35,40,13,7,29,39,11,13,32,37,11,13,32,25,42,16,27,17,39,10,11,33,24,5,39,15,19,49,44,9,44,18,10,50,8,22,44,37,25,4,8,18,25,49,41,26,39,31,31,31,25,43,43,5,16,21,26,10,23,11,29,11,4,28,27,8,4,12,26,46,48,17,16,13,50,22,43,14,16,19,34,42,10,33,14,22,11,44,20,32,29,3,22,3,23,5,9,16,15,35,14,13,11,14,17,32,21,50,46,34,32,38,39,35,37,3,8,33,46,40,7,16,19,44,46,27,26,8,40,33,14,26,0,13,36,46,38,41,34,3,24,19,6,0,49,29,39,34,30,40,25,27,16,30,24,40,9,23,41,34,22,25,39,44,2,44,41,45,41,24,35,34,24,15,17,32,22,31,44,27,44,23,18,50,31,35,35,0,7,15,35,35,48,4,32,20,10,33,6,42,2,2,18,20,22,46,48,50,1,10,28,32,11,23,39,1,6,4,13,21,8,30,31,0,18,33,24,26,14,0,15,16,30,2,28,31,4,23,30,0,20,13,17,38,50,48,6,13,18,6,11,6,38,32,37,0,1,37,33,27,9,21,47,48,41,21,12,7,0,16,10,13,38,48,36,40,9,28,44,6,11,47,7,19,42,33,11,8,13,26,35,0,4,48,1,17,10,43,6,5,40,28,48,14,36,50,39,26,22,26,6,13,38,43,9,35,42,29,11,27,27,45,29,39,45,47,45,8,12,8,3,39,9,40,38,7,47,1,31,28,46,36,43,15,44,46,24,41,26,27,19,15,49,38,27,35,42,31,4,24,41,3,34,7,50,8,19,24,34,0,30,45,41,2,48,45,33,40,4,46,28,35,8,24,50,26,13,49,44,48,50,6,39,5,45,2,16,4,39,49,43,6,44,45,24,10,20,2,19,22,25,0,41,9,40,46,7,25,44,50,40,46,10,7,40,21,2,26,23,43,23,7,27,33,19,17,41,21,39,18,40,20,3,47,50,50,22,23,40,32,23,19,45,30,15,15,49,22,32,50,35,27,38,19,0,29,32,29,5,40,40,38,32,30,48,30,8,10,10,50,50,12,25,5,23,49,34,43,0,27,41,27,17,0,36,38,21,21,11,44,49,36,12,5,12,40,49,37,43,27,0,11,45,47,49,1,36,29,16,12,9,41,29,17,18,32,35,45,14,25,16,23,45,14,42,36,43,32,10,27,39,4,39,43,46,14,17,18,46,12,16,50,21,10,22,49,10,22,10,9,22,11,1,19,48,29,9,32,31,12,38,45,32,35,38,15,46,7,45,38,44,6,12,38,42,49,26,36,30,32,19,4,35,45,5,41,35,46,12,22,27,21,25,22,20,44,23,42,0,20,3,10,14,16,32,34,6,8,18,0,5,19,35,46,9,46,32,19,16,35,8,50,6,5,50,1,42,44,31,42,24,0,22,8,47,2,26,39,27,34,21,7,11,27,19,3,22,46,42,8,11,45,41,33,30,9,6,8,6,42,32,6,30,16,28,42,42,42,25,35,7,34,32,11,42,2,32,34,47,33,47,43,8,24,29,1,4,24,11,29,23,25,7,5,21,16,23,39,35,30,11,49,4,34,18,7,21,18,35,44,40,23,10,5,1,36,47,44,44,33,12,15,43,47,2,16,5,5,8,49,19,8,1,20,23,41,34,37,19,40,17,43,44,14,13,42,39,50,5,1,7,20,31,30,25,3,15,44,21,33,30,35,23,3,25,9,34,34,50,0,9,8,14,24,1,5,27,39,45,50,0,12,37,27,39,33,11,5,30,49,46,10,16,6,50,32,28,38,43,2,23,1,29,20,40,36,9,2,10,3,32,32,45,15,5,5,32,8,50,25,27,49,0,4,29,11,38,0,0,31,27,32,6,50,25,18,29,40,33,22,28,43,9,48,12,50,33,3,22,30,44,28,6,3,24,17,16,30,32,49,50,3,42,14,32,1,33,33,43,46,8,36,3,13,6,18,25,12,6,27,5,50,3,38,6,33,14,31,15,8,13,26,7,3,21,20,41,20,44,2,15,27,28,22,14,10,13,48,6,47,0,33,42,7,30,39,20,34,27,34,22,2,37,8,23,34,47,16,6,19,10,36,21,49,28,31,44,31,25,7,47,20,39,35,6,4,25,47,50,30,16,7,34,18,20,3,39,38,16,0,6,45,1,31,9,46,31,26,49,11,11,33,1,37,29,13,33,19,49,17,18,33,20,7,28,24,44,18,10,34,26,1,19,36,4,36,8,27,45,18,11,23,28,46,24,44,35,19,27,12,38,10,5,48,49,0,50,36,18,25,35,12,25,40,41,24,34,28,35,31,48,5,46,8,14,3,47,4,33,1,23,10,1,19,32,2,32,48,5,2,10,3,48,41,0,11,27,13,23,23,18,26,24,17,44,42,34,46,50,8,30,40,45,42,15,49,21,18,10,34,45,36,15,5,15,50,42,6,28,45,20,46,24,44,19,13,22,46,6,48,34,11,42,38,16,16,50,23,14,32,20,23,35,7,46,0,11,48,50,35,21,5,41,23,23,17,8,8,26,0,36,26,19,18,30,11,18,33,21,12,12,47,32,38,3,11,14,20,16,8,33,29,14,16,42,19,25,28,6,41,27,45,24,34,6,3,34,38,49,32,44,42,18,7,26,21,2,8,41,23,45,44,46,36,46,40,2,48,29,43,35,21,4,39,1,9,35,2,9,0,14,37,17,8,25,32,47,47,16,17,27,31,9,4,15,34,17,41,50,8,26,43,12,31,44,11,19,31,29,8,2,50,21,5,36,28,1,30,35,45,17,34,45,48,2,41,4,28,22,9,12,41,0,12,48,42,3,12,31,30,33,32,41,35,19,5,2,25,19,46,32,8,6,45,35,12,7,38,35,30,35,30,1,37,43,44,20,50,48,4,5,1,40,5,4,47,8,26,43,46,29,21,28,4,45,17,36,16,16,28,18,1,37,27,25,49,18,6,8,30,19,9,19,4,30,2,17,29,17,41,18,34,3,37,46,5,45,31,43,23,40,43,19,45,4,38,37,46,35,49,0,21,5,49,45,21,50,5,32,42,31,31,13,19,47,34,40,1,9,36,36,48,7,49,33,2,17,22,28,41,23,29,9,26,11,44,12,9,18,13,39,4,18,2,14,30,20,26,19,48,10,15,6,48,16,15,14,41,32,16,49,42,7,37,16,35,9,11,50,41,23,37,37,13,32,37,17,28,2,19,2,28,18,12,38,8,24,26,48,21,48,23,18,44,32,31,48,22,6,16,6,27,10,12,16,30,19,24,41,21,31,12,2,28,19,28,34,49,12,38,13,21,27,37,4,29,23,34,50,5,50,36,16,35,46,39,33,37,50,46,45,30,6,34,15,43,25,12,41,26,50,7,32,32,21,30,47,4,29,8,33,36,48,10,3,23,18,23,43,9,45,45,21,41,15,8,9,42,16,17,2,37,25,36,12,15,4,49,46,32,6,44,12,49,31,3,47,15,3,2,8,28,41,18,44,22,11,28,2,25,26,38,2,22,38,34,39,4,15,47,40,36,34,9,29,46,36,27,26,14,12,1,28,8,29,19,30,28,46,1,4,28,39,25,47,17,18,37,5,17,0,34,39,6,24,1,50,15,10,45,48,7,18,23,32,28,38,46,24,33,45,32,50,34,31,35,40,8,40,14,19,14,48,39,18,32,36,27,0,1,39,46,48,37,46,30,0,5,8,23,42,42,10,2,9,47,50,30,19,25,1,28,8,46,30,44,50,22,20,7,15,14,1,24,32,41,5,16,1,8,20,3,6,37,15,45,21,49,28,37,43,27,22,12,38,2,10,27,32,40,40,30,13,41,25,33,6,5,39,17,7,13,11,41,0,3,49,35,33,21,41,38,9,1,43,6,50,10,30,1,20,11,50,29,1,9,33,36,40,43,5,28,48,4,44,11,9,43,32,48,20,7,13,0,42,40,27,42,12,46,18,45,25,19,17,33,49,38,30,1,13,21,12,41,26,36,11,28,14,45,43,20,10,21,29,0,24,25,0,43,36,18,47,31,5,9,15,41,25,0,48,3,37,19,24,36,32,6,47,32,22,35,16,40,38,23,2,39,27,31,2,11,37,38,44,40,46,29,31,42,13,46,6,47,16,28,23,42,40,48,25,35,41,45,21,15,11,7,27,2,17,44,40,2,19,40,9,4,14,8,47,10,26,33,29,25,41,0,49,1,37,17,16,12,50,46,37,8,10,1,5,24,16,43,8,9,20,37,2,1,4,45,34,28,21,50,8,46,38,16,38,12,11,20,47,44,34,42,27,26,13,6,40,8,4,36,18,10,47,2,48,5,50,38,37,16,39,16,50,4,23,16,44,6,20,37,50,40,25,50,29,30,42,21,37,5,45,1,34,28,26,3,4,18,20,39,5,22,35,47,34,7,24,33,50,43,0,23,11,32,18,22,25,6,29,23,29,36,6,44,39,44,0,3,8,16,41,22,21,1,24,18,18,33,24,39,8,26,6,50,17,3,30,41,44,1,11,2,3,42,19,2,30,16,1,22,18,46,2,33,10,3,36,43,41,41,50,20,21,28,33,45,14,24,24,33,16,11,44,35,24,50,23,33,7,17,20,11,49,27,22,39,19,21,44,33,36,39,5,50,6,0,16,16,28,36,42,47,45,18,36,35,18,47,7,45,44,37,24,12,35,25,26,10,13,3,29,14,16,26,45,43,9,33,25,3,42,33,18,30,28,7,18,1,33,50,20,41,6,35,9,15,23,48,25,1,33,3,24,16,10,42,50,10,20,28,32,45,32,9,21,20,10,16,10,36,8,49), 83)
30
+ }
31
+
32
+ }
count_beautiful_substrings_i/haskell_tests/Main.hs ADDED
@@ -0,0 +1,45 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ module Main where
3
+ import Test.HUnit
4
+
5
+ --Program start
6
+
7
+ --Program end
8
+
9
+ -- Test cases
10
+
11
+ test1 :: Test
12
+ test1 = TestCase (assertEqual "for (beautifulSubstrings \"baeyh \" 2)," 2 (beautifulSubstrings "baeyh" 2))
13
+
14
+ test2 :: Test
15
+ test2 = TestCase (assertEqual "for (beautifulSubstrings \"abba \" 1)," 3 (beautifulSubstrings "abba" 1))
16
+
17
+ test3 :: Test
18
+ test3 = TestCase (assertEqual "for (beautifulSubstrings \"bcdf \" 1)," 0 (beautifulSubstrings "bcdf" 1))
19
+
20
+ test4 :: Test
21
+ test4 = TestCase (assertEqual "for (beautifulSubstrings \"ctjodkwsatjlyxpxkwchvkhtxvdkirphcggiftuifrnpefjywshxmcsrqaeuuxlfziwtskuafkkkpoxdqsiqiauuvbjbwpnusmszocicejecssspzhfhtgmamgfojgpniumprheckmxwyhzzulyiezvuxnpshpgekojeoltwhezlrsppeapbvyyeuhhvpbeezuwdcwaxkgyalprgzmtkdpghzjivndasjxuogzeigrjcxquuhcowvshidesjlnthwlulbggwrbgvwbrftdxfjmwkoqtntbkgfgqsupstibrlnvopkhvmzbhoabcyfvnlcpvpaufaqjsgekqiffaakeivfareljuprtmleoooufxvxxdryjiesxhqk \" 670)," 0 (beautifulSubstrings "ctjodkwsatjlyxpxkwchvkhtxvdkirphcggiftuifrnpefjywshxmcsrqaeuuxlfziwtskuafkkkpoxdqsiqiauuvbjbwpnusmszocicejecssspzhfhtgmamgfojgpniumprheckmxwyhzzulyiezvuxnpshpgekojeoltwhezlrsppeapbvyyeuhhvpbeezuwdcwaxkgyalprgzmtkdpghzjivndasjxuogzeigrjcxquuhcowvshidesjlnthwlulbggwrbgvwbrftdxfjmwkoqtntbkgfgqsupstibrlnvopkhvmzbhoabcyfvnlcpvpaufaqjsgekqiffaakeivfareljuprtmleoooufxvxxdryjiesxhqk" 670))
22
+
23
+ test5 :: Test
24
+ test5 = TestCase (assertEqual "for (beautifulSubstrings \"tvfpodepegsskmnhugzuomwnodhhxxsugmfqzzwqpegnghbghdfpqsydgihjcpjhmbnnbecjcvzonrocnxbblwbupajmsxfsucxamklcxvgzletbwxfrihitieilutroggsdwhmdxnrkyxxdtrvazjyoiuhnykkpqrhqktoqezcjdoffjfyyjghuzocyhnnwlmetiimkligshhpeirfqkdvcmshgzomzjoxgldmhwwqmqqvjfjylcleqogztdzdoywryrvjrublrfqmplkbnscuvsprsdapmjqtfpkoxodtdnnngwigluymsrklrdwvahxdyuigxprnpknqtjeaqzduwgcdwobvdulqadlbmszprzisjbzdwpcgjbookenuqrmtsvvhmmqgxxaltfwqzvpjrcikadjkalptiyfasdeuoydtrfxxycxekvvghcmafsckpjyoclvguggehihivkljyjzhwmzclhfwmyqxnhfhmehcejtlkwhfqeahpllnrwojvqzwkirjmaaqkdgrwckqniqdyxsmitcvzaoqfphadpucazxihcfxkfikqnykcmquzlnivndlveyqlnzsrgyctsmqzztvleukczwukelqzszqsovtdvjdihfgmgkdqrzlhwoviqdvkgfrzrsrdbxytjguxwblmsetjpbdukchsrtqeuzpuvcrhthpmqdcpsrencgobuzyktsnpmrypfxluyqjzyqhjampzjyfkxhxpqtonywvcgzdknydytrygmwcbsbgfvvlauahexohoxsfmpendmybcbzrzwtbnrbfkagcdkshtzeebkebacvppgokozkdqmqgidggkepipgeyelqnvyizverbnomy \" 455)," 0 (beautifulSubstrings "tvfpodepegsskmnhugzuomwnodhhxxsugmfqzzwqpegnghbghdfpqsydgihjcpjhmbnnbecjcvzonrocnxbblwbupajmsxfsucxamklcxvgzletbwxfrihitieilutroggsdwhmdxnrkyxxdtrvazjyoiuhnykkpqrhqktoqezcjdoffjfyyjghuzocyhnnwlmetiimkligshhpeirfqkdvcmshgzomzjoxgldmhwwqmqqvjfjylcleqogztdzdoywryrvjrublrfqmplkbnscuvsprsdapmjqtfpkoxodtdnnngwigluymsrklrdwvahxdyuigxprnpknqtjeaqzduwgcdwobvdulqadlbmszprzisjbzdwpcgjbookenuqrmtsvvhmmqgxxaltfwqzvpjrcikadjkalptiyfasdeuoydtrfxxycxekvvghcmafsckpjyoclvguggehihivkljyjzhwmzclhfwmyqxnhfhmehcejtlkwhfqeahpllnrwojvqzwkirjmaaqkdgrwckqniqdyxsmitcvzaoqfphadpucazxihcfxkfikqnykcmquzlnivndlveyqlnzsrgyctsmqzztvleukczwukelqzszqsovtdvjdihfgmgkdqrzlhwoviqdvkgfrzrsrdbxytjguxwblmsetjpbdukchsrtqeuzpuvcrhthpmqdcpsrencgobuzyktsnpmrypfxluyqjzyqhjampzjyfkxhxpqtonywvcgzdknydytrygmwcbsbgfvvlauahexohoxsfmpendmybcbzrzwtbnrbfkagcdkshtzeebkebacvppgokozkdqmqgidggkepipgeyelqnvyizverbnomy" 455))
25
+
26
+ test6 :: Test
27
+ test6 = TestCase (assertEqual "for (beautifulSubstrings \"leayshlhovhjmcojnpbvyafruwyiboquodtgkvnatbettskfpoggqeguohblepimtdpsyazfvhpuxeifztahiyluurpmhkctucdncaebfffjlshilbbynaiilebmndawrijxtxggdejacgtpsgwioflktowrdlxvfgwgtmyhblxalbaizcqgkjgdtqvhhdittpankikrqdapubngogzapehelusnrxfooqsdgnmabzqemswtzwylokeyrpefupmmtiphvrereizxycfhmhisunbusudbspeckdxlsvyvojjivssxzrvxtkbgxarwzhhecvfbbnbpaewpucwxquoqbrprnbnktycgewtfhoojblyajtoojtbykmcgsvwsnfjwrhonubybfxsptubswmqmxhjlbxaaxedsgtiqrgslsapkmvldejtcypuqdhibyxflxxdrqpnaygfgjohcqywnsnlgfbtfykrmhgbtupeiysublosqsypsyoguxnjscwgxfekdnexutswccnymivgukcfvybyhgnteyesvwjsmdhoaotcoocyafqyvyxwctkdcaxgphwxpyucxmhmxhhmkgutdvbbalpxqasjixqfhdfmcfrhmesceaiiucfsapduxugkunjzhnhuuvkivdmglvwwrswhdvsspskuosvsasuwkwlakxevpnfobnwjzskcoowhhkslfektjiabodsthvphiiexolmspqnwfvymxoqnaavlsdsucplrskgsjwnobjmhujiewantihxmevqtxdaloextzsnosctwdotzvvpccijaffxubarqwfkxpfrlhghbgtghvwvrlxnbogbdsxlfwcaynnzacbmqgjyarremnhwfrjpcnerqcnvpql \" 480)," 0 (beautifulSubstrings "leayshlhovhjmcojnpbvyafruwyiboquodtgkvnatbettskfpoggqeguohblepimtdpsyazfvhpuxeifztahiyluurpmhkctucdncaebfffjlshilbbynaiilebmndawrijxtxggdejacgtpsgwioflktowrdlxvfgwgtmyhblxalbaizcqgkjgdtqvhhdittpankikrqdapubngogzapehelusnrxfooqsdgnmabzqemswtzwylokeyrpefupmmtiphvrereizxycfhmhisunbusudbspeckdxlsvyvojjivssxzrvxtkbgxarwzhhecvfbbnbpaewpucwxquoqbrprnbnktycgewtfhoojblyajtoojtbykmcgsvwsnfjwrhonubybfxsptubswmqmxhjlbxaaxedsgtiqrgslsapkmvldejtcypuqdhibyxflxxdrqpnaygfgjohcqywnsnlgfbtfykrmhgbtupeiysublosqsypsyoguxnjscwgxfekdnexutswccnymivgukcfvybyhgnteyesvwjsmdhoaotcoocyafqyvyxwctkdcaxgphwxpyucxmhmxhhmkgutdvbbalpxqasjixqfhdfmcfrhmesceaiiucfsapduxugkunjzhnhuuvkivdmglvwwrswhdvsspskuosvsasuwkwlakxevpnfobnwjzskcoowhhkslfektjiabodsthvphiiexolmspqnwfvymxoqnaavlsdsucplrskgsjwnobjmhujiewantihxmevqtxdaloextzsnosctwdotzvvpccijaffxubarqwfkxpfrlhghbgtghvwvrlxnbogbdsxlfwcaynnzacbmqgjyarremnhwfrjpcnerqcnvpql" 480))
28
+
29
+ test7 :: Test
30
+ test7 = TestCase (assertEqual "for (beautifulSubstrings \"ilsusmrloyodrgzrvyzcedvjlyoegzsgkedxnsxmblbjmjsjsvkoyskkarlffrgaultjmfnstrvybuykbojuikyspnwaknfvouomcrahinbnnvvaqyhxiqbjenitkkhcshdjfvmzvvhmdjldyjpmalyvxgmeyfvmjgkadspzqeuxomxxsfhaogncgfwouqrydhqkhbnqkklmwdytrdgnnkudzljvlncapnuvrdqvnyatwskakgxqyqmrupjzbgmsuadiaytrxyudapentstabfmfolztpw \" 907)," 0 (beautifulSubstrings "ilsusmrloyodrgzrvyzcedvjlyoegzsgkedxnsxmblbjmjsjsvkoyskkarlffrgaultjmfnstrvybuykbojuikyspnwaknfvouomcrahinbnnvvaqyhxiqbjenitkkhcshdjfvmzvvhmdjldyjpmalyvxgmeyfvmjgkadspzqeuxomxxsfhaogncgfwouqrydhqkhbnqkklmwdytrdgnnkudzljvlncapnuvrdqvnyatwskakgxqyqmrupjzbgmsuadiaytrxyudapentstabfmfolztpw" 907))
31
+
32
+ test8 :: Test
33
+ test8 = TestCase (assertEqual "for (beautifulSubstrings \"uzltyrfwnthpokxlyfsxa \" 58)," 0 (beautifulSubstrings "uzltyrfwnthpokxlyfsxa" 58))
34
+
35
+ test9 :: Test
36
+ test9 = TestCase (assertEqual "for (beautifulSubstrings \"hkuhlqqpkswnlwsjemrdgerllttyetnavwttgmanngkczcpfjjkxubgxlmeshusvzyaigvvstclhqzbhbipwgneluwwnrywyaecqibcnbjnmlubrkgnuawfgdxzobrgxbbhfrgnpgfczynqwtwzlwqnyvmtvyakmpdibviaesyfbkyzqwyfcqrifncshxmpfjylbnzfewocinjgoopcvwpmmyafaumdhonhddmxadfpfwylnfqwjvbtcpxwicuunxbnrhkzxoknhyazanvnlxnvngxhmoqsogmendqmylkxfkqtuymdrlbtbhcggqkcxbdsgkbqzdirysylwasnwgbdzjyvioxvztqqavxcvpyzfpkpyykyauutqnruraddefnqsoezuovcfrfcswpewrrbpexvkelcryntpxnxepklsxewoifrqrwyhinbknfgxypfvcrgyinxywmpsprcdchlgcrsluzflyhrnbjczxnqzgbhcjghxymwpfzsynllmtfazwdtdpzwjowbxwkwtkpijlktsxwxyehbwnqiojorvhsnxgfapnsynsvtlgximwaanzxqzpmurhmosvjehdlgscpdwlurfflvgdfstyjoqzizwxyrwlxposqzfljtdxbtgijzccshgdvltu \" 539)," 0 (beautifulSubstrings "hkuhlqqpkswnlwsjemrdgerllttyetnavwttgmanngkczcpfjjkxubgxlmeshusvzyaigvvstclhqzbhbipwgneluwwnrywyaecqibcnbjnmlubrkgnuawfgdxzobrgxbbhfrgnpgfczynqwtwzlwqnyvmtvyakmpdibviaesyfbkyzqwyfcqrifncshxmpfjylbnzfewocinjgoopcvwpmmyafaumdhonhddmxadfpfwylnfqwjvbtcpxwicuunxbnrhkzxoknhyazanvnlxnvngxhmoqsogmendqmylkxfkqtuymdrlbtbhcggqkcxbdsgkbqzdirysylwasnwgbdzjyvioxvztqqavxcvpyzfpkpyykyauutqnruraddefnqsoezuovcfrfcswpewrrbpexvkelcryntpxnxepklsxewoifrqrwyhinbknfgxypfvcrgyinxywmpsprcdchlgcrsluzflyhrnbjczxnqzgbhcjghxymwpfzsynllmtfazwdtdpzwjowbxwkwtkpijlktsxwxyehbwnqiojorvhsnxgfapnsynsvtlgximwaanzxqzpmurhmosvjehdlgscpdwlurfflvgdfstyjoqzizwxyrwlxposqzfljtdxbtgijzccshgdvltu" 539))
37
+
38
+
39
+ -- Grouping test cases
40
+ tests :: Test
41
+ tests = TestList [TestLabel "Test1" test1, TestLabel "Test2" test2, TestLabel "Test3" test3, TestLabel "Test4" test4, TestLabel "Test5" test5, TestLabel "Test6" test6, TestLabel "Test7" test7, TestLabel "Test8" test8, TestLabel "Test9" test9]
42
+
43
+ -- Running the tests
44
+ main :: IO Counts
45
+ main = runTestTT tests
count_beautiful_substrings_i/java_tests/Main.java ADDED
@@ -0,0 +1,25 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ import static org.junit.jupiter.api.Assertions.*;
3
+ import org.junit.jupiter.api.Test;
4
+ import java.util.List;
5
+ import java.util.Arrays;
6
+ import java.util.ArrayList;
7
+ public class Main {
8
+ //Program start
9
+
10
+ //Program end
11
+
12
+ @Test
13
+ public void test1() {
14
+ assertEquals(2, beautifulSubstrings("baeyh", 2));
15
+ }
16
+ @Test
17
+ public void test2() {
18
+ assertEquals(3, beautifulSubstrings("abba", 1));
19
+ }
20
+ @Test
21
+ public void test3() {
22
+ assertEquals(0, beautifulSubstrings("bcdf", 1));
23
+ }
24
+
25
+ }
count_beautiful_substrings_i/meta.json ADDED
@@ -0,0 +1,102 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "id": 3210,
3
+ "name": "count_beautiful_substrings_i",
4
+ "difficulty": "Medium",
5
+ "link": "https://leetcode.com/problems/count-beautiful-substrings-i/",
6
+ "date": "2023-11-19 00:00:00",
7
+ "task_description": "You are given a string `s` and a positive integer `k`. Let `vowels` and `consonants` be the number of vowels and consonants in a string. A string is **beautiful** if: `vowels == consonants`. `(vowels * consonants) % k == 0`, in other terms the multiplication of `vowels` and `consonants` is divisible by `k`. Return _the number of **non-empty beautiful substrings** in the given string_ `s`. A **substring** is a contiguous sequence of characters in a string. **Vowel letters** in English are `'a'`, `'e'`, `'i'`, `'o'`, and `'u'`. **Consonant letters** in English are every letter except vowels. **Example 1:** ``` **Input:** s = \"baeyh\", k = 2 **Output:** 2 **Explanation:** There are 2 beautiful substrings in the given string. - Substring \"baeyh\", vowels = 2 ([\"a\",e\"]), consonants = 2 ([\"y\",\"h\"]). You can see that string \"aeyh\" is beautiful as vowels == consonants and vowels * consonants % k == 0. - Substring \"baeyh\", vowels = 2 ([\"a\",e\"]), consonants = 2 ([\"b\",\"y\"]). You can see that string \"baey\" is beautiful as vowels == consonants and vowels * consonants % k == 0. It can be shown that there are only 2 beautiful substrings in the given string. ``` **Example 2:** ``` **Input:** s = \"abba\", k = 1 **Output:** 3 **Explanation:** There are 3 beautiful substrings in the given string. - Substring \"abba\", vowels = 1 ([\"a\"]), consonants = 1 ([\"b\"]). - Substring \"abba\", vowels = 1 ([\"a\"]), consonants = 1 ([\"b\"]). - Substring \"abba\", vowels = 2 ([\"a\",\"a\"]), consonants = 2 ([\"b\",\"b\"]). It can be shown that there are only 3 beautiful substrings in the given string. ``` **Example 3:** ``` **Input:** s = \"bcdf\", k = 1 **Output:** 0 **Explanation:** There are no beautiful substrings in the given string. ``` **Constraints:** `1 <= s.length <= 1000` `1 <= k <= 1000` `s` consists of only English lowercase letters.",
8
+ "public_test_cases": [
9
+ {
10
+ "label": "Example 1",
11
+ "input": "s = \"baeyh\", k = 2",
12
+ "output": "2 "
13
+ },
14
+ {
15
+ "label": "Example 2",
16
+ "input": "s = \"abba\", k = 1",
17
+ "output": "3 "
18
+ },
19
+ {
20
+ "label": "Example 3",
21
+ "input": "s = \"bcdf\", k = 1",
22
+ "output": "0 "
23
+ }
24
+ ],
25
+ "private_test_cases": [
26
+ {
27
+ "input": [
28
+ "\"ctjodkwsatjlyxpxkwchvkhtxvdkirphcggiftuifrnpefjywshxmcsrqaeuuxlfziwtskuafkkkpoxdqsiqiauuvbjbwpnusmszocicejecssspzhfhtgmamgfojgpniumprheckmxwyhzzulyiezvuxnpshpgekojeoltwhezlrsppeapbvyyeuhhvpbeezuwdcwaxkgyalprgzmtkdpghzjivndasjxuogzeigrjcxquuhcowvshidesjlnthwlulbggwrbgvwbrftdxfjmwkoqtntbkgfgqsupstibrlnvopkhvmzbhoabcyfvnlcpvpaufaqjsgekqiffaakeivfareljuprtmleoooufxvxxdryjiesxhqk\"",
29
+ 670
30
+ ],
31
+ "output": 0
32
+ },
33
+ {
34
+ "input": [
35
+ "\"tvfpodepegsskmnhugzuomwnodhhxxsugmfqzzwqpegnghbghdfpqsydgihjcpjhmbnnbecjcvzonrocnxbblwbupajmsxfsucxamklcxvgzletbwxfrihitieilutroggsdwhmdxnrkyxxdtrvazjyoiuhnykkpqrhqktoqezcjdoffjfyyjghuzocyhnnwlmetiimkligshhpeirfqkdvcmshgzomzjoxgldmhwwqmqqvjfjylcleqogztdzdoywryrvjrublrfqmplkbnscuvsprsdapmjqtfpkoxodtdnnngwigluymsrklrdwvahxdyuigxprnpknqtjeaqzduwgcdwobvdulqadlbmszprzisjbzdwpcgjbookenuqrmtsvvhmmqgxxaltfwqzvpjrcikadjkalptiyfasdeuoydtrfxxycxekvvghcmafsckpjyoclvguggehihivkljyjzhwmzclhfwmyqxnhfhmehcejtlkwhfqeahpllnrwojvqzwkirjmaaqkdgrwckqniqdyxsmitcvzaoqfphadpucazxihcfxkfikqnykcmquzlnivndlveyqlnzsrgyctsmqzztvleukczwukelqzszqsovtdvjdihfgmgkdqrzlhwoviqdvkgfrzrsrdbxytjguxwblmsetjpbdukchsrtqeuzpuvcrhthpmqdcpsrencgobuzyktsnpmrypfxluyqjzyqhjampzjyfkxhxpqtonywvcgzdknydytrygmwcbsbgfvvlauahexohoxsfmpendmybcbzrzwtbnrbfkagcdkshtzeebkebacvppgokozkdqmqgidggkepipgeyelqnvyizverbnomy\"",
36
+ 455
37
+ ],
38
+ "output": 0
39
+ },
40
+ {
41
+ "input": [
42
+ "\"leayshlhovhjmcojnpbvyafruwyiboquodtgkvnatbettskfpoggqeguohblepimtdpsyazfvhpuxeifztahiyluurpmhkctucdncaebfffjlshilbbynaiilebmndawrijxtxggdejacgtpsgwioflktowrdlxvfgwgtmyhblxalbaizcqgkjgdtqvhhdittpankikrqdapubngogzapehelusnrxfooqsdgnmabzqemswtzwylokeyrpefupmmtiphvrereizxycfhmhisunbusudbspeckdxlsvyvojjivssxzrvxtkbgxarwzhhecvfbbnbpaewpucwxquoqbrprnbnktycgewtfhoojblyajtoojtbykmcgsvwsnfjwrhonubybfxsptubswmqmxhjlbxaaxedsgtiqrgslsapkmvldejtcypuqdhibyxflxxdrqpnaygfgjohcqywnsnlgfbtfykrmhgbtupeiysublosqsypsyoguxnjscwgxfekdnexutswccnymivgukcfvybyhgnteyesvwjsmdhoaotcoocyafqyvyxwctkdcaxgphwxpyucxmhmxhhmkgutdvbbalpxqasjixqfhdfmcfrhmesceaiiucfsapduxugkunjzhnhuuvkivdmglvwwrswhdvsspskuosvsasuwkwlakxevpnfobnwjzskcoowhhkslfektjiabodsthvphiiexolmspqnwfvymxoqnaavlsdsucplrskgsjwnobjmhujiewantihxmevqtxdaloextzsnosctwdotzvvpccijaffxubarqwfkxpfrlhghbgtghvwvrlxnbogbdsxlfwcaynnzacbmqgjyarremnhwfrjpcnerqcnvpql\"",
43
+ 480
44
+ ],
45
+ "output": 0
46
+ },
47
+ {
48
+ "input": [
49
+ "\"ilsusmrloyodrgzrvyzcedvjlyoegzsgkedxnsxmblbjmjsjsvkoyskkarlffrgaultjmfnstrvybuykbojuikyspnwaknfvouomcrahinbnnvvaqyhxiqbjenitkkhcshdjfvmzvvhmdjldyjpmalyvxgmeyfvmjgkadspzqeuxomxxsfhaogncgfwouqrydhqkhbnqkklmwdytrdgnnkudzljvlncapnuvrdqvnyatwskakgxqyqmrupjzbgmsuadiaytrxyudapentstabfmfolztpw\"",
50
+ 907
51
+ ],
52
+ "output": 0
53
+ },
54
+ {
55
+ "input": [
56
+ "\"uzltyrfwnthpokxlyfsxa\"",
57
+ 58
58
+ ],
59
+ "output": 0
60
+ },
61
+ {
62
+ "input": [
63
+ "\"hkuhlqqpkswnlwsjemrdgerllttyetnavwttgmanngkczcpfjjkxubgxlmeshusvzyaigvvstclhqzbhbipwgneluwwnrywyaecqibcnbjnmlubrkgnuawfgdxzobrgxbbhfrgnpgfczynqwtwzlwqnyvmtvyakmpdibviaesyfbkyzqwyfcqrifncshxmpfjylbnzfewocinjgoopcvwpmmyafaumdhonhddmxadfpfwylnfqwjvbtcpxwicuunxbnrhkzxoknhyazanvnlxnvngxhmoqsogmendqmylkxfkqtuymdrlbtbhcggqkcxbdsgkbqzdirysylwasnwgbdzjyvioxvztqqavxcvpyzfpkpyykyauutqnruraddefnqsoezuovcfrfcswpewrrbpexvkelcryntpxnxepklsxewoifrqrwyhinbknfgxypfvcrgyinxywmpsprcdchlgcrsluzflyhrnbjczxnqzgbhcjghxymwpfzsynllmtfazwdtdpzwjowbxwkwtkpijlktsxwxyehbwnqiojorvhsnxgfapnsynsvtlgximwaanzxqzpmurhmosvjehdlgscpdwlurfflvgdfstyjoqzizwxyrwlxposqzfljtdxbtgijzccshgdvltu\"",
64
+ 539
65
+ ],
66
+ "output": 0
67
+ },
68
+ {
69
+ "input": [
70
+ "\"fjkajpxyfvsjpymysmtijuznbvdekynnkxmrvszamxultzdgdmwegabwawlawtaqhvlniejgfzbhpvepbpouiqaguqyjutipgwdttjhfnbzxhjprvxynhakuouxlbtgwllzzposfqrijtpodurywpziwzknrlyzikpscbhepalcsyhvchyiuyqfsidbszbwbffojlpchyamdxrfyfvmovamapfuztrmgxuxpgvhixwbkqlrjzcvptubzqarkfnspagyrokliheotzbetfjrmdussosgjzossoysviydyinnplcdayxcltyiqkhmptakdjqlqqhmghykyceqtglicnwszvkugnnwlnqcbxzvpihfdtfntnzrcxnjbdpfiqlypfezduwlrzlryqekpvgkrazgjvqepduazhchgwrufsfzhvqwikbgyqjhsduuzlzgvhiedukrenrszaogadyamrryecslmizctcqkyhhrxoiwuuzggwoebceezvnbplswbbboebbyehkxgisbjyyuecftecovyyurxdrbqhymmvaqwojqtwkacxleeobyhimsqjghpgmlksxtugpbowdcizpyrfxvxmjhofkhrdtfhipugldaplotruuaitlbftcsuasrttqbsmpbaulyjzqzqzywvysbteptiqxmeotwiclugeqrsnvshqhzldotnqlbybvsukykmzkrkclblejcrbiqiwdvjkpnzdolfphrfustijcjibuvwuwdgqszrxkjlxsrfranvdvtgfgpodxecqazqj\"",
71
+ 351
72
+ ],
73
+ "output": 0
74
+ },
75
+ {
76
+ "input": [
77
+ "yacizlutlzqkeangldcdymlchghvplczwxbzwsdkobethxxnqfhzllkukmmzpygfronnqgfdaidhcfosgxftzjhapywdyqjbdqvyvyqhnkinceqfvmtlbyqjystkgcjzkgsbnzyushkctcvqwybmgbezqwbggkhuejazgbndpzqkqekktmfddrsdquivxbmxzcvabzwfeendyphxhvzhqwkyderepayqwlkbypovwkzlldkkiyakofflvlzqiplsghkguyfwmlzrrccynbqd",
78
+ 352
79
+ ],
80
+ "output": 0
81
+ },
82
+ {
83
+ "input": [
84
+ "jiydlbcrhaatomioquyntircneoelotgbxnddyjhjvleqbcjbhhhvoofjdthnftpqmnggyfffyqkmhgjxaxxxfxrqpmznhuuksxdckjbhscikvjiurzbbwkozguhjnwttclnlczhivubbgkogbvgzeexfxpkraknvycwobkqfqilvcnggcjdjtdiqiuaueewvajvxupqnxujlhjkpknbitkvllcghymnkxl",
85
+ 780
86
+ ],
87
+ "output": 0
88
+ },
89
+ {
90
+ "input": [
91
+ "hzfcxspkmcuiqorblkgzppvelehfqcsssmbeimpduksuimvjlxoacsgspgormnoiolghntatjqfnubwtdrmwlzsbchejcoymimsoqsflmebcyqpjbjaqjvygpjvjtzdtmblykmzehyruojuhglwpuawxzcgobjpnnclgcpijrjrtmibluyzijyxjltjbcatnubejtjnnrbskmnhwoqxhxqmslbhzsxgrrhjrdscqsfbvipsxyhargnrexobvqbgbescsrihauzveaduckrotsrfoysdvvfhqgjwlmvsjxsmiifworvuyfzlvogjtpowmiaqouefvxfexzaqlesuvvlkntcja",
92
+ 231
93
+ ],
94
+ "output": 0
95
+ }
96
+ ],
97
+ "haskell_template": "beautifulSubstrings :: String -> Int -> Int\nbeautifulSubstrings s k ",
98
+ "ocaml_template": "let beautifulSubstrings (s: string) (k: int) : int = ",
99
+ "scala_template": "def beautifulSubstrings(s: String,k: Int): Int = { \n \n}",
100
+ "java_template": "class Solution {\n public int beautifulSubstrings(String s, int k) {\n \n }\n}",
101
+ "python_template": "class Solution(object):\n def beautifulSubstrings(self, s, k):\n \"\"\"\n :type s: str\n :type k: int\n :rtype: int\n \"\"\"\n "
102
+ }
count_beautiful_substrings_i/ocaml_tests/main.ml ADDED
@@ -0,0 +1,50 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ module Main = struct
3
+ open OUnit2
4
+
5
+ (* Program start *)
6
+
7
+ (* Program end *)
8
+
9
+ (* Test cases *)
10
+
11
+ let test1 _ = assert_equal 2 (beautifulSubstrings "baeyh" 2)
12
+
13
+ let test2 _ = assert_equal 3 (beautifulSubstrings "abba" 1)
14
+
15
+ let test3 _ = assert_equal 0 (beautifulSubstrings "bcdf" 1)
16
+
17
+ let test4 _ = assert_equal 0 (beautifulSubstrings "ctjodkwsatjlyxpxkwchvkhtxvdkirphcggiftuifrnpefjywshxmcsrqaeuuxlfziwtskuafkkkpoxdqsiqiauuvbjbwpnusmszocicejecssspzhfhtgmamgfojgpniumprheckmxwyhzzulyiezvuxnpshpgekojeoltwhezlrsppeapbvyyeuhhvpbeezuwdcwaxkgyalprgzmtkdpghzjivndasjxuogzeigrjcxquuhcowvshidesjlnthwlulbggwrbgvwbrftdxfjmwkoqtntbkgfgqsupstibrlnvopkhvmzbhoabcyfvnlcpvpaufaqjsgekqiffaakeivfareljuprtmleoooufxvxxdryjiesxhqk" 670)
18
+
19
+ let test5 _ = assert_equal 0 (beautifulSubstrings "tvfpodepegsskmnhugzuomwnodhhxxsugmfqzzwqpegnghbghdfpqsydgihjcpjhmbnnbecjcvzonrocnxbblwbupajmsxfsucxamklcxvgzletbwxfrihitieilutroggsdwhmdxnrkyxxdtrvazjyoiuhnykkpqrhqktoqezcjdoffjfyyjghuzocyhnnwlmetiimkligshhpeirfqkdvcmshgzomzjoxgldmhwwqmqqvjfjylcleqogztdzdoywryrvjrublrfqmplkbnscuvsprsdapmjqtfpkoxodtdnnngwigluymsrklrdwvahxdyuigxprnpknqtjeaqzduwgcdwobvdulqadlbmszprzisjbzdwpcgjbookenuqrmtsvvhmmqgxxaltfwqzvpjrcikadjkalptiyfasdeuoydtrfxxycxekvvghcmafsckpjyoclvguggehihivkljyjzhwmzclhfwmyqxnhfhmehcejtlkwhfqeahpllnrwojvqzwkirjmaaqkdgrwckqniqdyxsmitcvzaoqfphadpucazxihcfxkfikqnykcmquzlnivndlveyqlnzsrgyctsmqzztvleukczwukelqzszqsovtdvjdihfgmgkdqrzlhwoviqdvkgfrzrsrdbxytjguxwblmsetjpbdukchsrtqeuzpuvcrhthpmqdcpsrencgobuzyktsnpmrypfxluyqjzyqhjampzjyfkxhxpqtonywvcgzdknydytrygmwcbsbgfvvlauahexohoxsfmpendmybcbzrzwtbnrbfkagcdkshtzeebkebacvppgokozkdqmqgidggkepipgeyelqnvyizverbnomy" 455)
20
+
21
+ let test6 _ = assert_equal 0 (beautifulSubstrings "leayshlhovhjmcojnpbvyafruwyiboquodtgkvnatbettskfpoggqeguohblepimtdpsyazfvhpuxeifztahiyluurpmhkctucdncaebfffjlshilbbynaiilebmndawrijxtxggdejacgtpsgwioflktowrdlxvfgwgtmyhblxalbaizcqgkjgdtqvhhdittpankikrqdapubngogzapehelusnrxfooqsdgnmabzqemswtzwylokeyrpefupmmtiphvrereizxycfhmhisunbusudbspeckdxlsvyvojjivssxzrvxtkbgxarwzhhecvfbbnbpaewpucwxquoqbrprnbnktycgewtfhoojblyajtoojtbykmcgsvwsnfjwrhonubybfxsptubswmqmxhjlbxaaxedsgtiqrgslsapkmvldejtcypuqdhibyxflxxdrqpnaygfgjohcqywnsnlgfbtfykrmhgbtupeiysublosqsypsyoguxnjscwgxfekdnexutswccnymivgukcfvybyhgnteyesvwjsmdhoaotcoocyafqyvyxwctkdcaxgphwxpyucxmhmxhhmkgutdvbbalpxqasjixqfhdfmcfrhmesceaiiucfsapduxugkunjzhnhuuvkivdmglvwwrswhdvsspskuosvsasuwkwlakxevpnfobnwjzskcoowhhkslfektjiabodsthvphiiexolmspqnwfvymxoqnaavlsdsucplrskgsjwnobjmhujiewantihxmevqtxdaloextzsnosctwdotzvvpccijaffxubarqwfkxpfrlhghbgtghvwvrlxnbogbdsxlfwcaynnzacbmqgjyarremnhwfrjpcnerqcnvpql" 480)
22
+
23
+ let test7 _ = assert_equal 0 (beautifulSubstrings "ilsusmrloyodrgzrvyzcedvjlyoegzsgkedxnsxmblbjmjsjsvkoyskkarlffrgaultjmfnstrvybuykbojuikyspnwaknfvouomcrahinbnnvvaqyhxiqbjenitkkhcshdjfvmzvvhmdjldyjpmalyvxgmeyfvmjgkadspzqeuxomxxsfhaogncgfwouqrydhqkhbnqkklmwdytrdgnnkudzljvlncapnuvrdqvnyatwskakgxqyqmrupjzbgmsuadiaytrxyudapentstabfmfolztpw" 907)
24
+
25
+ let test8 _ = assert_equal 0 (beautifulSubstrings "uzltyrfwnthpokxlyfsxa" 58)
26
+
27
+ let test9 _ = assert_equal 0 (beautifulSubstrings "hkuhlqqpkswnlwsjemrdgerllttyetnavwttgmanngkczcpfjjkxubgxlmeshusvzyaigvvstclhqzbhbipwgneluwwnrywyaecqibcnbjnmlubrkgnuawfgdxzobrgxbbhfrgnpgfczynqwtwzlwqnyvmtvyakmpdibviaesyfbkyzqwyfcqrifncshxmpfjylbnzfewocinjgoopcvwpmmyafaumdhonhddmxadfpfwylnfqwjvbtcpxwicuunxbnrhkzxoknhyazanvnlxnvngxhmoqsogmendqmylkxfkqtuymdrlbtbhcggqkcxbdsgkbqzdirysylwasnwgbdzjyvioxvztqqavxcvpyzfpkpyykyauutqnruraddefnqsoezuovcfrfcswpewrrbpexvkelcryntpxnxepklsxewoifrqrwyhinbknfgxypfvcrgyinxywmpsprcdchlgcrsluzflyhrnbjczxnqzgbhcjghxymwpfzsynllmtfazwdtdpzwjowbxwkwtkpijlktsxwxyehbwnqiojorvhsnxgfapnsynsvtlgximwaanzxqzpmurhmosvjehdlgscpdwlurfflvgdfstyjoqzizwxyrwlxposqzfljtdxbtgijzccshgdvltu" 539)
28
+
29
+ let test10 _ = assert_equal 0 (beautifulSubstrings "fjkajpxyfvsjpymysmtijuznbvdekynnkxmrvszamxultzdgdmwegabwawlawtaqhvlniejgfzbhpvepbpouiqaguqyjutipgwdttjhfnbzxhjprvxynhakuouxlbtgwllzzposfqrijtpodurywpziwzknrlyzikpscbhepalcsyhvchyiuyqfsidbszbwbffojlpchyamdxrfyfvmovamapfuztrmgxuxpgvhixwbkqlrjzcvptubzqarkfnspagyrokliheotzbetfjrmdussosgjzossoysviydyinnplcdayxcltyiqkhmptakdjqlqqhmghykyceqtglicnwszvkugnnwlnqcbxzvpihfdtfntnzrcxnjbdpfiqlypfezduwlrzlryqekpvgkrazgjvqepduazhchgwrufsfzhvqwikbgyqjhsduuzlzgvhiedukrenrszaogadyamrryecslmizctcqkyhhrxoiwuuzggwoebceezvnbplswbbboebbyehkxgisbjyyuecftecovyyurxdrbqhymmvaqwojqtwkacxleeobyhimsqjghpgmlksxtugpbowdcizpyrfxvxmjhofkhrdtfhipugldaplotruuaitlbftcsuasrttqbsmpbaulyjzqzqzywvysbteptiqxmeotwiclugeqrsnvshqhzldotnqlbybvsukykmzkrkclblejcrbiqiwdvjkpnzdolfphrfustijcjibuvwuwdgqszrxkjlxsrfranvdvtgfgpodxecqazqj" 351)
30
+
31
+
32
+ (* Grouping test cases *)
33
+ let suite = "Test Suite for beautifulSubstrings" >::: [
34
+
35
+ "test1" >:: test1;
36
+ "test2" >:: test2;
37
+ "test3" >:: test3;
38
+ "test4" >:: test4;
39
+ "test5" >:: test5;
40
+ "test6" >:: test6;
41
+ "test7" >:: test7;
42
+ "test8" >:: test8;
43
+ "test9" >:: test9;
44
+ "test10" >:: test10;
45
+ ]
46
+
47
+
48
+ (* Running the tests *)
49
+ let () = run_test_tt_main suite
50
+ end
count_beautiful_substrings_i/scala_tests/MySuite.scala ADDED
@@ -0,0 +1,44 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ class MySuite extends munit.FunSuite {
3
+
4
+ test("test1") {
5
+ assertEquals(Main.beautifulSubstrings("baeyh",2), 2)
6
+ }
7
+
8
+ test("test2") {
9
+ assertEquals(Main.beautifulSubstrings("abba",1), 3)
10
+ }
11
+
12
+ test("test3") {
13
+ assertEquals(Main.beautifulSubstrings("bcdf",1), 0)
14
+ }
15
+
16
+ test("test4") {
17
+ assertEquals(Main.beautifulSubstrings("ctjodkwsatjlyxpxkwchvkhtxvdkirphcggiftuifrnpefjywshxmcsrqaeuuxlfziwtskuafkkkpoxdqsiqiauuvbjbwpnusmszocicejecssspzhfhtgmamgfojgpniumprheckmxwyhzzulyiezvuxnpshpgekojeoltwhezlrsppeapbvyyeuhhvpbeezuwdcwaxkgyalprgzmtkdpghzjivndasjxuogzeigrjcxquuhcowvshidesjlnthwlulbggwrbgvwbrftdxfjmwkoqtntbkgfgqsupstibrlnvopkhvmzbhoabcyfvnlcpvpaufaqjsgekqiffaakeivfareljuprtmleoooufxvxxdryjiesxhqk",670), 0)
18
+ }
19
+
20
+ test("test5") {
21
+ assertEquals(Main.beautifulSubstrings("tvfpodepegsskmnhugzuomwnodhhxxsugmfqzzwqpegnghbghdfpqsydgihjcpjhmbnnbecjcvzonrocnxbblwbupajmsxfsucxamklcxvgzletbwxfrihitieilutroggsdwhmdxnrkyxxdtrvazjyoiuhnykkpqrhqktoqezcjdoffjfyyjghuzocyhnnwlmetiimkligshhpeirfqkdvcmshgzomzjoxgldmhwwqmqqvjfjylcleqogztdzdoywryrvjrublrfqmplkbnscuvsprsdapmjqtfpkoxodtdnnngwigluymsrklrdwvahxdyuigxprnpknqtjeaqzduwgcdwobvdulqadlbmszprzisjbzdwpcgjbookenuqrmtsvvhmmqgxxaltfwqzvpjrcikadjkalptiyfasdeuoydtrfxxycxekvvghcmafsckpjyoclvguggehihivkljyjzhwmzclhfwmyqxnhfhmehcejtlkwhfqeahpllnrwojvqzwkirjmaaqkdgrwckqniqdyxsmitcvzaoqfphadpucazxihcfxkfikqnykcmquzlnivndlveyqlnzsrgyctsmqzztvleukczwukelqzszqsovtdvjdihfgmgkdqrzlhwoviqdvkgfrzrsrdbxytjguxwblmsetjpbdukchsrtqeuzpuvcrhthpmqdcpsrencgobuzyktsnpmrypfxluyqjzyqhjampzjyfkxhxpqtonywvcgzdknydytrygmwcbsbgfvvlauahexohoxsfmpendmybcbzrzwtbnrbfkagcdkshtzeebkebacvppgokozkdqmqgidggkepipgeyelqnvyizverbnomy",455), 0)
22
+ }
23
+
24
+ test("test6") {
25
+ assertEquals(Main.beautifulSubstrings("leayshlhovhjmcojnpbvyafruwyiboquodtgkvnatbettskfpoggqeguohblepimtdpsyazfvhpuxeifztahiyluurpmhkctucdncaebfffjlshilbbynaiilebmndawrijxtxggdejacgtpsgwioflktowrdlxvfgwgtmyhblxalbaizcqgkjgdtqvhhdittpankikrqdapubngogzapehelusnrxfooqsdgnmabzqemswtzwylokeyrpefupmmtiphvrereizxycfhmhisunbusudbspeckdxlsvyvojjivssxzrvxtkbgxarwzhhecvfbbnbpaewpucwxquoqbrprnbnktycgewtfhoojblyajtoojtbykmcgsvwsnfjwrhonubybfxsptubswmqmxhjlbxaaxedsgtiqrgslsapkmvldejtcypuqdhibyxflxxdrqpnaygfgjohcqywnsnlgfbtfykrmhgbtupeiysublosqsypsyoguxnjscwgxfekdnexutswccnymivgukcfvybyhgnteyesvwjsmdhoaotcoocyafqyvyxwctkdcaxgphwxpyucxmhmxhhmkgutdvbbalpxqasjixqfhdfmcfrhmesceaiiucfsapduxugkunjzhnhuuvkivdmglvwwrswhdvsspskuosvsasuwkwlakxevpnfobnwjzskcoowhhkslfektjiabodsthvphiiexolmspqnwfvymxoqnaavlsdsucplrskgsjwnobjmhujiewantihxmevqtxdaloextzsnosctwdotzvvpccijaffxubarqwfkxpfrlhghbgtghvwvrlxnbogbdsxlfwcaynnzacbmqgjyarremnhwfrjpcnerqcnvpql",480), 0)
26
+ }
27
+
28
+ test("test7") {
29
+ assertEquals(Main.beautifulSubstrings("ilsusmrloyodrgzrvyzcedvjlyoegzsgkedxnsxmblbjmjsjsvkoyskkarlffrgaultjmfnstrvybuykbojuikyspnwaknfvouomcrahinbnnvvaqyhxiqbjenitkkhcshdjfvmzvvhmdjldyjpmalyvxgmeyfvmjgkadspzqeuxomxxsfhaogncgfwouqrydhqkhbnqkklmwdytrdgnnkudzljvlncapnuvrdqvnyatwskakgxqyqmrupjzbgmsuadiaytrxyudapentstabfmfolztpw",907), 0)
30
+ }
31
+
32
+ test("test8") {
33
+ assertEquals(Main.beautifulSubstrings("uzltyrfwnthpokxlyfsxa",58), 0)
34
+ }
35
+
36
+ test("test9") {
37
+ assertEquals(Main.beautifulSubstrings("hkuhlqqpkswnlwsjemrdgerllttyetnavwttgmanngkczcpfjjkxubgxlmeshusvzyaigvvstclhqzbhbipwgneluwwnrywyaecqibcnbjnmlubrkgnuawfgdxzobrgxbbhfrgnpgfczynqwtwzlwqnyvmtvyakmpdibviaesyfbkyzqwyfcqrifncshxmpfjylbnzfewocinjgoopcvwpmmyafaumdhonhddmxadfpfwylnfqwjvbtcpxwicuunxbnrhkzxoknhyazanvnlxnvngxhmoqsogmendqmylkxfkqtuymdrlbtbhcggqkcxbdsgkbqzdirysylwasnwgbdzjyvioxvztqqavxcvpyzfpkpyykyauutqnruraddefnqsoezuovcfrfcswpewrrbpexvkelcryntpxnxepklsxewoifrqrwyhinbknfgxypfvcrgyinxywmpsprcdchlgcrsluzflyhrnbjczxnqzgbhcjghxymwpfzsynllmtfazwdtdpzwjowbxwkwtkpijlktsxwxyehbwnqiojorvhsnxgfapnsynsvtlgximwaanzxqzpmurhmosvjehdlgscpdwlurfflvgdfstyjoqzizwxyrwlxposqzfljtdxbtgijzccshgdvltu",539), 0)
38
+ }
39
+
40
+ test("test10") {
41
+ assertEquals(Main.beautifulSubstrings("fjkajpxyfvsjpymysmtijuznbvdekynnkxmrvszamxultzdgdmwegabwawlawtaqhvlniejgfzbhpvepbpouiqaguqyjutipgwdttjhfnbzxhjprvxynhakuouxlbtgwllzzposfqrijtpodurywpziwzknrlyzikpscbhepalcsyhvchyiuyqfsidbszbwbffojlpchyamdxrfyfvmovamapfuztrmgxuxpgvhixwbkqlrjzcvptubzqarkfnspagyrokliheotzbetfjrmdussosgjzossoysviydyinnplcdayxcltyiqkhmptakdjqlqqhmghykyceqtglicnwszvkugnnwlnqcbxzvpihfdtfntnzrcxnjbdpfiqlypfezduwlrzlryqekpvgkrazgjvqepduazhchgwrufsfzhvqwikbgyqjhsduuzlzgvhiedukrenrszaogadyamrryecslmizctcqkyhhrxoiwuuzggwoebceezvnbplswbbboebbyehkxgisbjyyuecftecovyyurxdrbqhymmvaqwojqtwkacxleeobyhimsqjghpgmlksxtugpbowdcizpyrfxvxmjhofkhrdtfhipugldaplotruuaitlbftcsuasrttqbsmpbaulyjzqzqzywvysbteptiqxmeotwiclugeqrsnvshqhzldotnqlbybvsukykmzkrkclblejcrbiqiwdvjkpnzdolfphrfustijcjibuvwuwdgqszrxkjlxsrfranvdvtgfgpodxecqazqj",351), 0)
42
+ }
43
+
44
+ }
count_beautiful_substrings_ii/haskell_tests/Main.hs ADDED
The diff for this file is too large to render. See raw diff
 
count_beautiful_substrings_ii/java_tests/Main.java ADDED
@@ -0,0 +1,25 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ import static org.junit.jupiter.api.Assertions.*;
3
+ import org.junit.jupiter.api.Test;
4
+ import java.util.List;
5
+ import java.util.Arrays;
6
+ import java.util.ArrayList;
7
+ public class Main {
8
+ //Program start
9
+
10
+ //Program end
11
+
12
+ @Test
13
+ public void test1() {
14
+ assertEquals(2, beautifulSubstrings("baeyh", 2));
15
+ }
16
+ @Test
17
+ public void test2() {
18
+ assertEquals(3, beautifulSubstrings("abba", 1));
19
+ }
20
+ @Test
21
+ public void test3() {
22
+ assertEquals(0, beautifulSubstrings("bcdf", 1));
23
+ }
24
+
25
+ }
count_beautiful_substrings_ii/meta.json ADDED
The diff for this file is too large to render. See raw diff
 
count_beautiful_substrings_ii/ocaml_tests/main.ml ADDED
The diff for this file is too large to render. See raw diff
 
count_beautiful_substrings_ii/scala_tests/MySuite.scala ADDED
The diff for this file is too large to render. See raw diff
 
count_collisions_on_a_road/.DS_Store ADDED
Binary file (6.15 kB). View file
 
count_collisions_on_a_road/haskell_tests/Main.hs ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ module Main where
3
+ import Test.HUnit
4
+
5
+ --Program start
6
+
7
+ --Program end
8
+
9
+ -- Test cases
10
+
11
+ test1 :: Test
12
+ test1 = TestCase (assertEqual "for (countCollisions \"RLRSLL \")," 5 (countCollisions "RLRSLL"))
13
+
14
+ test2 :: Test
15
+ test2 = TestCase (assertEqual "for (countCollisions \"LLRR \")," 0 (countCollisions "LLRR"))
16
+
17
+
18
+ -- Grouping test cases
19
+ tests :: Test
20
+ tests = TestList [TestLabel "Test1" test1]
21
+
22
+ -- Running the tests
23
+ main :: IO Counts
24
+ main = runTestTT tests
count_collisions_on_a_road/java_tests/Main.java ADDED
@@ -0,0 +1,21 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ import static org.junit.jupiter.api.Assertions.*;
3
+ import org.junit.jupiter.api.Test;
4
+ import java.util.List;
5
+ import java.util.Arrays;
6
+ import java.util.ArrayList;
7
+ public class Main {
8
+ //Program start
9
+
10
+ //Program end
11
+
12
+ @Test
13
+ public void test1() {
14
+ assertEquals(5, countCollisions("RLRSLL"));
15
+ }
16
+ @Test
17
+ public void test2() {
18
+ assertEquals(0, countCollisions("LLRR"));
19
+ }
20
+
21
+ }
count_collisions_on_a_road/meta.json ADDED
The diff for this file is too large to render. See raw diff
 
count_collisions_on_a_road/ocaml_tests/main.ml ADDED
@@ -0,0 +1,26 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ module Main = struct
3
+ open OUnit2
4
+
5
+ (* Program start *)
6
+
7
+ (* Program end *)
8
+
9
+ (* Test cases *)
10
+
11
+ let test1 _ = assert_equal 5 (countCollisions "RLRSLL")
12
+
13
+ let test2 _ = assert_equal 0 (countCollisions "LLRR")
14
+
15
+
16
+ (* Grouping test cases *)
17
+ let suite = "Test Suite for countCollisions" >::: [
18
+
19
+ "test1" >:: test1;
20
+ "test2" >:: test2;
21
+ ]
22
+
23
+
24
+ (* Running the tests *)
25
+ let () = run_test_tt_main suite
26
+ end
count_collisions_on_a_road/scala_tests/MySuite.scala ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ class MySuite extends munit.FunSuite {
3
+
4
+ test("test1") {
5
+ assertEquals(Main.countCollisions("RLRSLL"), 5)
6
+ }
7
+
8
+ test("test2") {
9
+ assertEquals(Main.countCollisions("LLRR"), 0)
10
+ }
11
+
12
+ }
count_complete_subarrays_in_an_array/haskell_tests/Main.hs ADDED
@@ -0,0 +1,41 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ module Main where
3
+ import Test.HUnit
4
+
5
+ --Program start
6
+ countCompleteSubarrays :: [Int] -> Int
7
+ countCompleteSubarrays nums = undefined
8
+
9
+ --Program end
10
+
11
+ -- Test cases
12
+
13
+ test1 :: Test
14
+ test1 = TestCase (assertEqual "for (countCompleteSubarrays [1,3,1,2,2])," 4 (countCompleteSubarrays [1,3,1,2,2]))
15
+
16
+ test2 :: Test
17
+ test2 = TestCase (assertEqual "for (countCompleteSubarrays [5,5,5,5])," 10 (countCompleteSubarrays [5,5,5,5]))
18
+
19
+ test3 :: Test
20
+ test3 = TestCase (assertEqual "for (countCompleteSubarrays [985, 684, 1562, 107, 515, 123, 1924, 1501, 1874, 557, 1773, 800, 123, 827, 547, 1285, 357, 194, 227, 396, 192, 751, 72, 918, 1496, 1174, 1325, 1478, 821, 799, 164, 477, 1859, 1431, 302, 1636, 1061, 612, 211, 482, 1891, 898, 378, 1371, 1454, 1034, 1216, 1370, 1014, 1224, 1148, 1453, 1613, 204, 270, 1502, 1472, 1336, 1238, 966, 1761, 424, 642, 1589, 316, 71, 507, 241, 1810, 379, 1680, 1772, 1283, 1521, 1631, 465, 578, 83, 1762, 1435, 1743, 910, 725, 1707, 831, 571, 249, 241, 504, 150, 1239, 895, 1084, 345, 1593, 1420, 969, 640, 171, 1511, 1146, 918, 579, 1756, 753, 289, 6, 880, 777, 1513, 1384, 1928, 895, 854, 1642, 1498, 830, 533, 1050, 1045, 650, 1031, 1729, 381, 209, 1528, 1096, 941, 599, 931, 401, 1011, 1742, 584, 126, 134, 1224, 437, 711, 451, 1954, 1305, 1279, 1222, 1486, 1362, 1618, 1924, 86, 1928, 1401, 1089, 45, 1028, 903, 1626, 1544, 243, 917, 1274, 1475, 382, 1221, 550, 1484, 229, 108, 50, 1621, 1229, 1158, 1633, 1747, 1921, 1309, 418, 1147, 452, 1944, 766, 1006, 283, 159, 144, 1184, 1764, 980, 936, 450, 371, 103, 1735, 2, 857, 1035, 1809, 181, 1887, 997, 349, 1384, 1086, 279, 929, 1777, 1335, 607, 197, 221, 404, 1994, 738, 176, 1159, 1672, 1303, 536, 14, 1524, 1574, 259, 386, 758, 352, 429, 152, 894, 1269, 1814, 1957, 964, 1193, 1938, 2000, 398, 705, 828, 1420, 1328, 312, 1892, 110, 1572, 20, 649, 1156, 891, 979, 1337, 179, 760, 1712, 847, 407, 518, 553, 804, 708, 1914, 871, 453, 622, 987, 1370, 55, 710, 294, 827, 1872, 106, 91, 1695, 633, 301, 877, 64, 1759, 659, 515, 1519, 328, 535, 917, 1384, 607, 278, 512, 676, 480, 283, 1592, 965, 1490, 915, 194, 965, 1636, 86, 33, 1734, 317, 1226, 1802, 872, 983, 1220, 1016, 1963, 484, 1252, 724, 1291, 1189, 971, 239, 1002, 412, 109, 407, 1898, 743, 1048, 1367, 1106, 18, 1520, 1837, 1305, 51, 268, 1602, 1992, 1022, 1649, 1340, 1980, 1893, 1913, 524, 68, 1534, 290, 440, 183, 177, 587, 1553, 1186, 861, 405, 1355, 1386, 1078, 1564, 43, 1647, 1490, 1640, 856, 1510, 1949, 88, 739, 331, 89, 398, 1298, 1014, 970, 581, 1270, 241, 1540, 547, 826, 818, 1744, 555, 1383, 1299, 813, 1011, 550, 1295, 17, 1375, 712, 1679, 1793, 1774, 151, 1651, 1510, 192, 1929, 632, 1500, 992, 742, 1497, 463, 201, 1847, 1027, 1409, 1976, 1267, 402, 1995, 1438, 1397, 1975, 1938, 1826, 67, 1003, 1710, 752, 1996, 516, 1142, 1329, 913, 1332, 824, 1316, 223, 1020, 1610, 1792, 60, 332, 241, 1780, 1116, 423, 1144, 1849, 1305, 597, 112, 1224, 1332, 1207, 1515, 403, 160, 457, 1301, 698, 1983, 1558, 1284, 636, 437, 820, 1082, 1559, 1958, 1599, 1583, 1357, 1393, 1267, 675, 1378, 35, 1751, 1493, 105, 477, 1779, 1512, 1613, 460, 548, 16, 1085, 1142, 332, 161, 1086, 288, 1230, 1001, 419, 403, 356, 552, 877, 1915, 657, 699, 1089, 1093, 178, 1356, 1935, 1835, 1804, 179, 578, 658, 1784, 72, 1696, 841, 1063, 1074, 341, 625, 925, 240, 154, 1974, 1094, 1841, 1987, 334, 1676, 1844, 1302, 1252, 591, 1412, 518, 655, 360, 1753, 982, 240, 866, 629, 1084, 1654, 850, 570, 356, 1320, 1201, 924, 1809, 378, 107, 1907, 441, 1677, 1219, 256, 1033, 1589, 441, 95, 631, 1807, 1714, 994, 933, 1901, 111, 216, 1982, 1848, 465, 1338, 953, 124, 1245, 1811, 1281, 1403, 462, 1343, 728, 901, 132, 1311, 1570, 136, 1902, 1650, 689, 1080, 629, 1351, 656, 1029, 614, 27, 1742, 605, 1133, 1042, 1366, 589, 1788, 1876, 871, 466, 23, 794, 942, 1823, 1596, 649, 171, 1767, 1683, 702, 374, 780, 1831, 1228, 1159, 1866, 748, 344, 1551, 776, 247, 166, 1800, 953, 1097, 1351, 1200, 1444, 299, 1060, 1961, 9, 61, 1487, 6, 6, 1370, 735, 585, 1949, 1564, 1626, 1440, 1994, 1074, 80, 428, 543, 858, 1445, 813, 718, 1431, 20, 1045, 430, 996, 1992, 627, 741, 853, 1385, 1637, 684, 297, 430, 1141, 174, 631, 1499, 1623, 1303, 1078, 1719, 1045, 1894, 1932, 1114, 993, 1677, 833, 730, 1425, 800, 1945, 600, 1568, 1283, 30, 1629, 1426, 179, 163, 848, 1164, 284])," 1 (countCompleteSubarrays [985, 684, 1562, 107, 515, 123, 1924, 1501, 1874, 557, 1773, 800, 123, 827, 547, 1285, 357, 194, 227, 396, 192, 751, 72, 918, 1496, 1174, 1325, 1478, 821, 799, 164, 477, 1859, 1431, 302, 1636, 1061, 612, 211, 482, 1891, 898, 378, 1371, 1454, 1034, 1216, 1370, 1014, 1224, 1148, 1453, 1613, 204, 270, 1502, 1472, 1336, 1238, 966, 1761, 424, 642, 1589, 316, 71, 507, 241, 1810, 379, 1680, 1772, 1283, 1521, 1631, 465, 578, 83, 1762, 1435, 1743, 910, 725, 1707, 831, 571, 249, 241, 504, 150, 1239, 895, 1084, 345, 1593, 1420, 969, 640, 171, 1511, 1146, 918, 579, 1756, 753, 289, 6, 880, 777, 1513, 1384, 1928, 895, 854, 1642, 1498, 830, 533, 1050, 1045, 650, 1031, 1729, 381, 209, 1528, 1096, 941, 599, 931, 401, 1011, 1742, 584, 126, 134, 1224, 437, 711, 451, 1954, 1305, 1279, 1222, 1486, 1362, 1618, 1924, 86, 1928, 1401, 1089, 45, 1028, 903, 1626, 1544, 243, 917, 1274, 1475, 382, 1221, 550, 1484, 229, 108, 50, 1621, 1229, 1158, 1633, 1747, 1921, 1309, 418, 1147, 452, 1944, 766, 1006, 283, 159, 144, 1184, 1764, 980, 936, 450, 371, 103, 1735, 2, 857, 1035, 1809, 181, 1887, 997, 349, 1384, 1086, 279, 929, 1777, 1335, 607, 197, 221, 404, 1994, 738, 176, 1159, 1672, 1303, 536, 14, 1524, 1574, 259, 386, 758, 352, 429, 152, 894, 1269, 1814, 1957, 964, 1193, 1938, 2000, 398, 705, 828, 1420, 1328, 312, 1892, 110, 1572, 20, 649, 1156, 891, 979, 1337, 179, 760, 1712, 847, 407, 518, 553, 804, 708, 1914, 871, 453, 622, 987, 1370, 55, 710, 294, 827, 1872, 106, 91, 1695, 633, 301, 877, 64, 1759, 659, 515, 1519, 328, 535, 917, 1384, 607, 278, 512, 676, 480, 283, 1592, 965, 1490, 915, 194, 965, 1636, 86, 33, 1734, 317, 1226, 1802, 872, 983, 1220, 1016, 1963, 484, 1252, 724, 1291, 1189, 971, 239, 1002, 412, 109, 407, 1898, 743, 1048, 1367, 1106, 18, 1520, 1837, 1305, 51, 268, 1602, 1992, 1022, 1649, 1340, 1980, 1893, 1913, 524, 68, 1534, 290, 440, 183, 177, 587, 1553, 1186, 861, 405, 1355, 1386, 1078, 1564, 43, 1647, 1490, 1640, 856, 1510, 1949, 88, 739, 331, 89, 398, 1298, 1014, 970, 581, 1270, 241, 1540, 547, 826, 818, 1744, 555, 1383, 1299, 813, 1011, 550, 1295, 17, 1375, 712, 1679, 1793, 1774, 151, 1651, 1510, 192, 1929, 632, 1500, 992, 742, 1497, 463, 201, 1847, 1027, 1409, 1976, 1267, 402, 1995, 1438, 1397, 1975, 1938, 1826, 67, 1003, 1710, 752, 1996, 516, 1142, 1329, 913, 1332, 824, 1316, 223, 1020, 1610, 1792, 60, 332, 241, 1780, 1116, 423, 1144, 1849, 1305, 597, 112, 1224, 1332, 1207, 1515, 403, 160, 457, 1301, 698, 1983, 1558, 1284, 636, 437, 820, 1082, 1559, 1958, 1599, 1583, 1357, 1393, 1267, 675, 1378, 35, 1751, 1493, 105, 477, 1779, 1512, 1613, 460, 548, 16, 1085, 1142, 332, 161, 1086, 288, 1230, 1001, 419, 403, 356, 552, 877, 1915, 657, 699, 1089, 1093, 178, 1356, 1935, 1835, 1804, 179, 578, 658, 1784, 72, 1696, 841, 1063, 1074, 341, 625, 925, 240, 154, 1974, 1094, 1841, 1987, 334, 1676, 1844, 1302, 1252, 591, 1412, 518, 655, 360, 1753, 982, 240, 866, 629, 1084, 1654, 850, 570, 356, 1320, 1201, 924, 1809, 378, 107, 1907, 441, 1677, 1219, 256, 1033, 1589, 441, 95, 631, 1807, 1714, 994, 933, 1901, 111, 216, 1982, 1848, 465, 1338, 953, 124, 1245, 1811, 1281, 1403, 462, 1343, 728, 901, 132, 1311, 1570, 136, 1902, 1650, 689, 1080, 629, 1351, 656, 1029, 614, 27, 1742, 605, 1133, 1042, 1366, 589, 1788, 1876, 871, 466, 23, 794, 942, 1823, 1596, 649, 171, 1767, 1683, 702, 374, 780, 1831, 1228, 1159, 1866, 748, 344, 1551, 776, 247, 166, 1800, 953, 1097, 1351, 1200, 1444, 299, 1060, 1961, 9, 61, 1487, 6, 6, 1370, 735, 585, 1949, 1564, 1626, 1440, 1994, 1074, 80, 428, 543, 858, 1445, 813, 718, 1431, 20, 1045, 430, 996, 1992, 627, 741, 853, 1385, 1637, 684, 297, 430, 1141, 174, 631, 1499, 1623, 1303, 1078, 1719, 1045, 1894, 1932, 1114, 993, 1677, 833, 730, 1425, 800, 1945, 600, 1568, 1283, 30, 1629, 1426, 179, 163, 848, 1164, 284]))
21
+
22
+ test4 :: Test
23
+ test4 = TestCase (assertEqual "for (countCompleteSubarrays [447, 1820, 1472, 478, 50, 1364, 1189, 1957, 431, 1982, 139, 1875, 1987, 632, 1753, 1991, 1089, 214, 1947, 848, 737, 1149, 187, 1512, 1977, 1254, 1193, 496, 1498, 534, 1489, 665, 257, 620, 1452, 505, 1085, 617, 1990, 1127, 265, 99, 590, 1735, 1872, 34, 509, 916, 37, 1215, 1770, 512, 1753, 1103, 1046, 876, 1641, 1443, 1186, 786, 1182, 156, 530, 1672, 1367, 1834, 553, 54, 1526, 74, 722, 416, 1856, 865, 21, 1289, 905, 537, 1584, 755, 69, 370, 617, 925, 305, 632, 1547, 1661, 374, 1504, 584, 1101, 467, 218, 1494, 1137, 1214, 1554, 593, 1893, 157, 1545, 516, 824, 26, 138, 1669, 1756, 30, 1059, 1726, 652, 1475, 864, 738, 1547, 1856, 1517, 1218, 1958, 1865, 1272, 279, 1977, 319, 893, 845, 1789, 1113, 1254, 1845, 1034, 231, 1231, 1594, 1615, 1553, 1003, 922, 1219, 253, 1466, 1542, 347, 1672, 459, 1106, 1212, 1878, 1245, 509, 148, 1552, 662, 1382, 752, 1913, 1274, 1899, 1713, 1239, 1224, 1608, 100, 1587, 1677, 444, 352, 471, 500, 1182, 1019, 1417, 1522, 1862, 52, 823, 1942, 1183, 1121, 1111, 1642, 1766, 452, 1002, 1103, 963, 647, 819, 121, 409, 251, 1227, 1268, 1411, 1056, 297, 375, 1911, 1037, 1088, 848, 1635, 488, 873, 135, 496, 585, 347, 1660, 1439, 64, 1434, 666, 225, 992, 1014, 345, 152, 291, 1954, 1780, 1127, 1426, 703, 1980, 73, 707, 419, 856, 1026, 160, 915, 750, 405, 1041, 1005, 1146, 912, 890, 141, 1329, 777, 481, 451, 1937, 1924, 1417, 929, 1952, 1983, 1708, 1478, 1857, 1927, 1959, 405, 1853, 199, 301, 428, 1954, 1433, 1034, 1258, 1914, 22, 1516, 415, 2000, 1137, 1857, 1519, 185, 1136, 1965, 1565, 585, 1327, 1223, 596, 1187, 1859, 1468, 1238, 1471, 1244, 1424, 583, 1320, 140, 516, 1261, 1369, 1167, 1773, 1110, 1069, 1558, 418, 1884, 656, 1501, 476, 1150, 1159, 1145, 196, 321, 229, 1727, 526, 1410, 545, 364, 160, 1368, 1647, 627, 1411, 969, 1647, 1999, 1169, 1076, 475, 1443, 646, 1938, 1870, 67, 1136, 260, 1068, 1710, 1350, 1033, 1015, 860, 1215, 1767, 1608, 1422, 1927, 1831, 968, 1147, 1712, 952, 948, 333, 568, 357, 1103, 1372, 899, 750, 1528, 367, 1603, 1492, 947, 800, 554, 1215, 1934, 76, 1659, 1425, 1882, 260, 731, 1487, 1077, 1097, 1996, 33, 1378, 810, 652, 1201, 614, 1110, 1375, 690, 82, 1442, 648, 1416, 1849, 240, 520, 673, 532, 1608, 1752, 161, 1552, 294, 397, 111, 1431, 1306, 467, 1166, 1466, 902, 1069, 625, 440, 1520, 671, 266, 999, 226, 1825, 1649, 1473, 1090, 1929, 259, 1401, 646, 1889, 1515, 1624, 896, 1622, 1214, 1410, 376, 1866, 418, 26, 305, 254, 1324, 174, 1277, 781, 30, 604, 1451, 539, 610, 406, 472, 52, 833, 876, 45, 1283, 1822, 1710, 1403, 295, 671, 1757, 1404, 942, 1007, 1918, 1103, 1835, 152, 1916, 1751, 824, 1393, 1448, 1579, 792, 1620, 1850, 147, 69, 1191, 378, 1394, 208, 1619, 937, 21, 1944, 1320, 1037, 757, 426, 196, 85, 1495, 1994, 1535, 12, 1338, 843, 1359, 1834, 175, 435, 759, 1778, 1358, 1250, 1389, 1894, 1006, 522, 1605, 1161, 1745, 945, 1366, 1114, 1234, 54, 938, 1406, 143, 1889, 300, 141, 1289, 959, 1293, 330, 1757, 1039, 1417, 971, 360, 1728, 488, 1688, 544, 1497, 1818, 1410, 462, 215, 515, 1641, 103, 114, 1669, 291, 546, 1672, 937, 797, 1816, 1474, 318, 1451, 1592, 1417, 561, 904, 671, 291, 542, 896, 1820, 975, 1919, 1971, 360, 1026, 184, 1799, 459, 1218, 1423, 1019, 468, 725, 752, 1466, 102, 1617, 968, 1763, 1456, 1990, 1050, 1840, 630, 957, 594, 307, 267, 55, 1339, 1724, 1971, 275, 603, 1413, 665, 887, 301, 979, 469, 1503, 833, 1819, 1332, 1254, 284, 1452, 1920, 1362, 1937, 1586, 325, 890, 1385, 525, 378, 429, 1927, 325, 1176, 1823, 779, 1350, 657, 1695, 1393, 598, 842, 1088, 1283, 1938, 1860, 687, 614, 264, 778, 269, 1587, 1933, 1494, 1117, 1372, 1836, 1359, 1399, 1947, 1330, 587, 812, 893, 1316, 101, 1090, 1383, 1283, 1128, 118, 1520, 146, 1186, 552, 264, 182, 1736, 329, 835, 1676, 1143, 112, 1497, 494, 1781, 688, 1917, 207, 392, 241, 1139, 1135, 1123, 1477, 511, 1094, 462, 75, 1285, 1174, 1769, 1317, 965, 749, 526, 455, 1630, 19, 754, 1089, 1730, 842, 1946, 1873, 1740, 45, 878, 1223, 479, 1274, 1278, 706, 1581, 1284, 1390, 1955, 122, 1108, 505, 1706, 236, 820, 921, 1954, 572, 1179, 1911, 162, 864, 1087, 1372, 1839, 1972, 1653, 1606, 625, 85, 1070, 889, 37, 411, 1088, 1187, 84, 270, 1867, 1123, 911, 1145, 659, 1276, 1729, 575, 475, 1663, 794, 322, 1142, 737, 917, 1888, 448, 165, 1885, 1801, 390, 738, 1703, 1245, 1569, 1819, 1568, 1163, 377, 1497, 1703, 1657, 946, 1966, 112, 1046, 161, 1339, 941, 1215, 1506, 1013, 272, 764, 355, 233, 631, 1711, 1430, 1361, 1594, 1182, 200, 1735, 484, 250, 580, 417, 1359, 1837, 1380, 983, 1785, 845, 75, 1967, 349, 753, 1437, 142, 536, 143, 11, 1654, 919, 1455, 1178, 204, 1569, 907, 1445, 963, 492, 1215, 1571, 368, 1023])," 1 (countCompleteSubarrays [447, 1820, 1472, 478, 50, 1364, 1189, 1957, 431, 1982, 139, 1875, 1987, 632, 1753, 1991, 1089, 214, 1947, 848, 737, 1149, 187, 1512, 1977, 1254, 1193, 496, 1498, 534, 1489, 665, 257, 620, 1452, 505, 1085, 617, 1990, 1127, 265, 99, 590, 1735, 1872, 34, 509, 916, 37, 1215, 1770, 512, 1753, 1103, 1046, 876, 1641, 1443, 1186, 786, 1182, 156, 530, 1672, 1367, 1834, 553, 54, 1526, 74, 722, 416, 1856, 865, 21, 1289, 905, 537, 1584, 755, 69, 370, 617, 925, 305, 632, 1547, 1661, 374, 1504, 584, 1101, 467, 218, 1494, 1137, 1214, 1554, 593, 1893, 157, 1545, 516, 824, 26, 138, 1669, 1756, 30, 1059, 1726, 652, 1475, 864, 738, 1547, 1856, 1517, 1218, 1958, 1865, 1272, 279, 1977, 319, 893, 845, 1789, 1113, 1254, 1845, 1034, 231, 1231, 1594, 1615, 1553, 1003, 922, 1219, 253, 1466, 1542, 347, 1672, 459, 1106, 1212, 1878, 1245, 509, 148, 1552, 662, 1382, 752, 1913, 1274, 1899, 1713, 1239, 1224, 1608, 100, 1587, 1677, 444, 352, 471, 500, 1182, 1019, 1417, 1522, 1862, 52, 823, 1942, 1183, 1121, 1111, 1642, 1766, 452, 1002, 1103, 963, 647, 819, 121, 409, 251, 1227, 1268, 1411, 1056, 297, 375, 1911, 1037, 1088, 848, 1635, 488, 873, 135, 496, 585, 347, 1660, 1439, 64, 1434, 666, 225, 992, 1014, 345, 152, 291, 1954, 1780, 1127, 1426, 703, 1980, 73, 707, 419, 856, 1026, 160, 915, 750, 405, 1041, 1005, 1146, 912, 890, 141, 1329, 777, 481, 451, 1937, 1924, 1417, 929, 1952, 1983, 1708, 1478, 1857, 1927, 1959, 405, 1853, 199, 301, 428, 1954, 1433, 1034, 1258, 1914, 22, 1516, 415, 2000, 1137, 1857, 1519, 185, 1136, 1965, 1565, 585, 1327, 1223, 596, 1187, 1859, 1468, 1238, 1471, 1244, 1424, 583, 1320, 140, 516, 1261, 1369, 1167, 1773, 1110, 1069, 1558, 418, 1884, 656, 1501, 476, 1150, 1159, 1145, 196, 321, 229, 1727, 526, 1410, 545, 364, 160, 1368, 1647, 627, 1411, 969, 1647, 1999, 1169, 1076, 475, 1443, 646, 1938, 1870, 67, 1136, 260, 1068, 1710, 1350, 1033, 1015, 860, 1215, 1767, 1608, 1422, 1927, 1831, 968, 1147, 1712, 952, 948, 333, 568, 357, 1103, 1372, 899, 750, 1528, 367, 1603, 1492, 947, 800, 554, 1215, 1934, 76, 1659, 1425, 1882, 260, 731, 1487, 1077, 1097, 1996, 33, 1378, 810, 652, 1201, 614, 1110, 1375, 690, 82, 1442, 648, 1416, 1849, 240, 520, 673, 532, 1608, 1752, 161, 1552, 294, 397, 111, 1431, 1306, 467, 1166, 1466, 902, 1069, 625, 440, 1520, 671, 266, 999, 226, 1825, 1649, 1473, 1090, 1929, 259, 1401, 646, 1889, 1515, 1624, 896, 1622, 1214, 1410, 376, 1866, 418, 26, 305, 254, 1324, 174, 1277, 781, 30, 604, 1451, 539, 610, 406, 472, 52, 833, 876, 45, 1283, 1822, 1710, 1403, 295, 671, 1757, 1404, 942, 1007, 1918, 1103, 1835, 152, 1916, 1751, 824, 1393, 1448, 1579, 792, 1620, 1850, 147, 69, 1191, 378, 1394, 208, 1619, 937, 21, 1944, 1320, 1037, 757, 426, 196, 85, 1495, 1994, 1535, 12, 1338, 843, 1359, 1834, 175, 435, 759, 1778, 1358, 1250, 1389, 1894, 1006, 522, 1605, 1161, 1745, 945, 1366, 1114, 1234, 54, 938, 1406, 143, 1889, 300, 141, 1289, 959, 1293, 330, 1757, 1039, 1417, 971, 360, 1728, 488, 1688, 544, 1497, 1818, 1410, 462, 215, 515, 1641, 103, 114, 1669, 291, 546, 1672, 937, 797, 1816, 1474, 318, 1451, 1592, 1417, 561, 904, 671, 291, 542, 896, 1820, 975, 1919, 1971, 360, 1026, 184, 1799, 459, 1218, 1423, 1019, 468, 725, 752, 1466, 102, 1617, 968, 1763, 1456, 1990, 1050, 1840, 630, 957, 594, 307, 267, 55, 1339, 1724, 1971, 275, 603, 1413, 665, 887, 301, 979, 469, 1503, 833, 1819, 1332, 1254, 284, 1452, 1920, 1362, 1937, 1586, 325, 890, 1385, 525, 378, 429, 1927, 325, 1176, 1823, 779, 1350, 657, 1695, 1393, 598, 842, 1088, 1283, 1938, 1860, 687, 614, 264, 778, 269, 1587, 1933, 1494, 1117, 1372, 1836, 1359, 1399, 1947, 1330, 587, 812, 893, 1316, 101, 1090, 1383, 1283, 1128, 118, 1520, 146, 1186, 552, 264, 182, 1736, 329, 835, 1676, 1143, 112, 1497, 494, 1781, 688, 1917, 207, 392, 241, 1139, 1135, 1123, 1477, 511, 1094, 462, 75, 1285, 1174, 1769, 1317, 965, 749, 526, 455, 1630, 19, 754, 1089, 1730, 842, 1946, 1873, 1740, 45, 878, 1223, 479, 1274, 1278, 706, 1581, 1284, 1390, 1955, 122, 1108, 505, 1706, 236, 820, 921, 1954, 572, 1179, 1911, 162, 864, 1087, 1372, 1839, 1972, 1653, 1606, 625, 85, 1070, 889, 37, 411, 1088, 1187, 84, 270, 1867, 1123, 911, 1145, 659, 1276, 1729, 575, 475, 1663, 794, 322, 1142, 737, 917, 1888, 448, 165, 1885, 1801, 390, 738, 1703, 1245, 1569, 1819, 1568, 1163, 377, 1497, 1703, 1657, 946, 1966, 112, 1046, 161, 1339, 941, 1215, 1506, 1013, 272, 764, 355, 233, 631, 1711, 1430, 1361, 1594, 1182, 200, 1735, 484, 250, 580, 417, 1359, 1837, 1380, 983, 1785, 845, 75, 1967, 349, 753, 1437, 142, 536, 143, 11, 1654, 919, 1455, 1178, 204, 1569, 907, 1445, 963, 492, 1215, 1571, 368, 1023]))
24
+
25
+ test5 :: Test
26
+ test5 = TestCase (assertEqual "for (countCompleteSubarrays [737, 1335, 1825, 421, 1572, 417, 1369, 1940, 1590, 1688, 466, 1002, 1851, 1251, 413, 1771, 1878, 1353, 1994, 278, 1471, 1299, 968, 151, 143, 1471, 1433, 105, 1993, 1425, 777, 1220, 1922, 934, 1844, 1526, 1422, 1774, 1310, 1412, 1475, 319, 1214, 1812, 960, 1607, 1153, 961, 1566, 843, 495, 448, 577, 1668, 1207, 112, 1581, 1369, 764, 727, 1174, 1478, 1953, 821, 721, 1912, 185, 1686, 1349, 911, 1797, 977, 1601, 1700, 567, 925, 177, 1325, 1081, 324, 908, 673, 29, 1481, 400, 294, 813, 574, 651, 629, 779, 1076, 839, 1410, 116, 1112, 1124, 1600, 1296, 1442, 1269, 1652, 1158, 1480, 73, 1371, 671, 779, 951, 97, 798, 1825, 1317, 182, 1166, 962, 1425, 291, 1858, 557, 1974, 1586, 1924, 207, 948, 1684, 40, 1418, 485, 269, 1920, 1585, 1172, 594, 113, 131, 1807, 752, 102, 1304, 1849, 1038, 745, 365, 1667, 1342, 487, 1985, 1813, 471, 1993, 998, 1321, 607, 133, 356, 802, 1722, 1607, 242, 1901, 82, 1056, 1952, 1310, 1960, 1978, 1038, 1938, 339, 1838, 690, 1584, 1559, 1135, 1832, 1311, 474, 860, 1697, 468, 155, 1337, 596, 428, 390, 1754, 663, 615, 79, 1688, 1463, 1675, 342, 913, 281, 1745, 1301, 1535, 129, 1550, 1808, 512, 1487, 1740, 1849, 757, 1524, 449, 652, 529, 757, 1609, 276, 1289, 1499, 954, 176, 1265, 1844, 1745, 62, 911, 1183, 1873, 1791, 253, 227, 943, 586, 887, 647, 876, 1123, 1056, 37, 1775, 632, 1226, 667, 1882, 1464, 1797, 900, 1472, 1991, 399, 1333, 680, 806, 1362, 977, 1848, 482, 1218, 1317, 1396, 450, 1083, 427, 1227, 184, 41, 1201, 1903, 1882, 25, 371, 1333, 1119, 1833, 944, 1859])," 1 (countCompleteSubarrays [737, 1335, 1825, 421, 1572, 417, 1369, 1940, 1590, 1688, 466, 1002, 1851, 1251, 413, 1771, 1878, 1353, 1994, 278, 1471, 1299, 968, 151, 143, 1471, 1433, 105, 1993, 1425, 777, 1220, 1922, 934, 1844, 1526, 1422, 1774, 1310, 1412, 1475, 319, 1214, 1812, 960, 1607, 1153, 961, 1566, 843, 495, 448, 577, 1668, 1207, 112, 1581, 1369, 764, 727, 1174, 1478, 1953, 821, 721, 1912, 185, 1686, 1349, 911, 1797, 977, 1601, 1700, 567, 925, 177, 1325, 1081, 324, 908, 673, 29, 1481, 400, 294, 813, 574, 651, 629, 779, 1076, 839, 1410, 116, 1112, 1124, 1600, 1296, 1442, 1269, 1652, 1158, 1480, 73, 1371, 671, 779, 951, 97, 798, 1825, 1317, 182, 1166, 962, 1425, 291, 1858, 557, 1974, 1586, 1924, 207, 948, 1684, 40, 1418, 485, 269, 1920, 1585, 1172, 594, 113, 131, 1807, 752, 102, 1304, 1849, 1038, 745, 365, 1667, 1342, 487, 1985, 1813, 471, 1993, 998, 1321, 607, 133, 356, 802, 1722, 1607, 242, 1901, 82, 1056, 1952, 1310, 1960, 1978, 1038, 1938, 339, 1838, 690, 1584, 1559, 1135, 1832, 1311, 474, 860, 1697, 468, 155, 1337, 596, 428, 390, 1754, 663, 615, 79, 1688, 1463, 1675, 342, 913, 281, 1745, 1301, 1535, 129, 1550, 1808, 512, 1487, 1740, 1849, 757, 1524, 449, 652, 529, 757, 1609, 276, 1289, 1499, 954, 176, 1265, 1844, 1745, 62, 911, 1183, 1873, 1791, 253, 227, 943, 586, 887, 647, 876, 1123, 1056, 37, 1775, 632, 1226, 667, 1882, 1464, 1797, 900, 1472, 1991, 399, 1333, 680, 806, 1362, 977, 1848, 482, 1218, 1317, 1396, 450, 1083, 427, 1227, 184, 41, 1201, 1903, 1882, 25, 371, 1333, 1119, 1833, 944, 1859]))
27
+
28
+ test6 :: Test
29
+ test6 = TestCase (assertEqual "for (countCompleteSubarrays [808, 1892, 621, 1143, 1217, 1802, 1825, 927, 158, 739, 1135, 642, 1564, 1865, 1027, 1256, 1208, 458, 733, 1309, 1642, 1885, 35, 1901, 448, 1492, 146, 49, 910, 988, 580, 1927, 1074, 354, 1990, 439, 963, 1605, 1581, 1102, 559, 20, 1576, 1528, 651, 1734, 1796, 1864, 1358, 441, 232, 1522, 1451, 1519, 644, 734, 1342, 405, 1955, 1555, 1010, 1251, 1319, 747, 1079, 1779, 1394, 1056, 396, 704, 1519, 35, 1174, 1987, 126, 603, 313, 1550, 680, 1579, 788, 47, 336, 1448, 474, 1488, 388, 1487, 1923, 895, 1547, 865, 523, 1298, 1945, 1123, 1334, 1233, 1196, 897, 1109, 1505, 910, 820, 235, 1866, 642, 685, 1795, 1541, 1670, 1615, 202, 1560, 364, 1081, 1156, 1791, 815, 1078, 698, 1072, 1739, 1918, 1180, 1212, 1227, 1496, 1267, 1668, 1559, 1861, 1803, 386, 1655, 1653, 1626, 1336, 30, 1118, 301, 695, 1161, 1657, 1001, 128, 1329, 1010, 46, 80, 1176, 1785, 79, 1704, 537, 995, 346, 1419, 1782, 1819, 378, 1046, 754, 296, 624, 1376, 1373, 1064, 1117, 380, 25, 568, 1925, 766, 1494, 1160, 948, 1071, 374, 975, 1398, 1830, 529, 525, 972, 1291, 1128, 1749, 1432, 158, 1761, 820, 1149, 44, 1132, 1498, 1586, 801, 521, 1723, 219, 936, 966, 1920, 1399, 587, 480, 264, 396, 1397, 232, 666, 4, 386, 98, 202, 1427, 1576, 561, 596, 208, 1457, 246, 864, 993, 891, 215, 1028, 473, 1577, 1412, 417, 726, 597, 498, 987, 1211, 1472, 1545, 1201, 1339, 1899, 921, 584, 989, 332, 1329, 1005, 314, 473, 1316, 868, 1933, 707, 1118, 1993, 1626, 1806, 127, 643, 1857, 1292, 1140, 279, 1079, 1443, 529, 1870, 45, 969, 1666, 377, 542, 218, 174, 787, 1620, 1290, 187, 740, 947, 387, 1800, 1535, 119, 399, 993, 1846, 1291, 861, 60, 1534, 1519, 457, 1427, 1582, 1149, 984, 144, 613, 1982, 1723, 408, 245, 1411, 568, 606, 1680, 1530, 959, 688, 970, 922, 658, 1287, 1063, 1615, 1797, 1357, 821, 408, 1126, 1277, 616, 1652, 1024, 115, 1924, 1682, 561, 206, 1690, 1825, 240, 141, 849, 522, 1842, 1055, 121, 273, 795, 1007, 292, 373, 682, 1287, 749, 889, 319, 171, 1382, 1690, 927, 1172, 1277, 947, 1698, 1076, 1075, 522, 1621, 144, 472, 538, 735, 831, 226, 284, 1450, 1853, 139, 1174, 1154, 1785, 1509, 771, 390, 847, 110, 623, 560, 1615, 1334, 1903, 1631, 374, 1377, 389, 281, 229, 548, 1105, 630, 1583, 49, 1311, 1794, 783, 665, 256, 137, 1737, 748, 315, 952, 1333, 796, 1110, 371, 1651, 1812, 1884, 489, 387, 1900, 1648, 884, 1676, 1097, 1567, 949, 737, 1743, 548, 324, 251, 1693, 41, 663, 1039, 1507, 1754, 1351, 905, 915, 1750, 741, 1076, 1938, 460, 1183, 729, 1987, 987, 1055, 481, 795, 603, 1199, 19, 1719, 311, 86, 1501, 1434, 618, 1876, 1990, 742, 1894, 1129, 1197, 123, 800, 1935, 222, 1091, 1950, 953, 1908, 130, 658, 652, 478, 1745, 1677, 1651, 33, 1027, 1493, 253, 1925, 1523, 489, 1098, 1066, 128, 999, 1852, 178, 1850, 985, 1662, 338, 1078, 251, 1945, 894, 1637, 1446, 1738, 327, 401, 1149, 1556, 523, 1971, 1341, 2000, 196, 161, 1688, 1942, 3, 1371, 1403, 601, 1300, 1855, 812, 549, 938, 87, 1473, 1084, 868, 1171, 242, 1335, 1521, 1193, 1920, 1951, 1948, 1926, 484, 751, 1253, 1813, 296, 910, 192, 1002, 1467, 1548, 1652, 933, 270, 1719, 612, 1243, 1425, 1961, 226, 2, 1639, 1856, 37, 1072, 1438, 1428, 1557, 1679, 963, 1343, 830, 1818, 1027, 792, 1123, 1444, 191, 358, 988, 1367, 833])," 1 (countCompleteSubarrays [808, 1892, 621, 1143, 1217, 1802, 1825, 927, 158, 739, 1135, 642, 1564, 1865, 1027, 1256, 1208, 458, 733, 1309, 1642, 1885, 35, 1901, 448, 1492, 146, 49, 910, 988, 580, 1927, 1074, 354, 1990, 439, 963, 1605, 1581, 1102, 559, 20, 1576, 1528, 651, 1734, 1796, 1864, 1358, 441, 232, 1522, 1451, 1519, 644, 734, 1342, 405, 1955, 1555, 1010, 1251, 1319, 747, 1079, 1779, 1394, 1056, 396, 704, 1519, 35, 1174, 1987, 126, 603, 313, 1550, 680, 1579, 788, 47, 336, 1448, 474, 1488, 388, 1487, 1923, 895, 1547, 865, 523, 1298, 1945, 1123, 1334, 1233, 1196, 897, 1109, 1505, 910, 820, 235, 1866, 642, 685, 1795, 1541, 1670, 1615, 202, 1560, 364, 1081, 1156, 1791, 815, 1078, 698, 1072, 1739, 1918, 1180, 1212, 1227, 1496, 1267, 1668, 1559, 1861, 1803, 386, 1655, 1653, 1626, 1336, 30, 1118, 301, 695, 1161, 1657, 1001, 128, 1329, 1010, 46, 80, 1176, 1785, 79, 1704, 537, 995, 346, 1419, 1782, 1819, 378, 1046, 754, 296, 624, 1376, 1373, 1064, 1117, 380, 25, 568, 1925, 766, 1494, 1160, 948, 1071, 374, 975, 1398, 1830, 529, 525, 972, 1291, 1128, 1749, 1432, 158, 1761, 820, 1149, 44, 1132, 1498, 1586, 801, 521, 1723, 219, 936, 966, 1920, 1399, 587, 480, 264, 396, 1397, 232, 666, 4, 386, 98, 202, 1427, 1576, 561, 596, 208, 1457, 246, 864, 993, 891, 215, 1028, 473, 1577, 1412, 417, 726, 597, 498, 987, 1211, 1472, 1545, 1201, 1339, 1899, 921, 584, 989, 332, 1329, 1005, 314, 473, 1316, 868, 1933, 707, 1118, 1993, 1626, 1806, 127, 643, 1857, 1292, 1140, 279, 1079, 1443, 529, 1870, 45, 969, 1666, 377, 542, 218, 174, 787, 1620, 1290, 187, 740, 947, 387, 1800, 1535, 119, 399, 993, 1846, 1291, 861, 60, 1534, 1519, 457, 1427, 1582, 1149, 984, 144, 613, 1982, 1723, 408, 245, 1411, 568, 606, 1680, 1530, 959, 688, 970, 922, 658, 1287, 1063, 1615, 1797, 1357, 821, 408, 1126, 1277, 616, 1652, 1024, 115, 1924, 1682, 561, 206, 1690, 1825, 240, 141, 849, 522, 1842, 1055, 121, 273, 795, 1007, 292, 373, 682, 1287, 749, 889, 319, 171, 1382, 1690, 927, 1172, 1277, 947, 1698, 1076, 1075, 522, 1621, 144, 472, 538, 735, 831, 226, 284, 1450, 1853, 139, 1174, 1154, 1785, 1509, 771, 390, 847, 110, 623, 560, 1615, 1334, 1903, 1631, 374, 1377, 389, 281, 229, 548, 1105, 630, 1583, 49, 1311, 1794, 783, 665, 256, 137, 1737, 748, 315, 952, 1333, 796, 1110, 371, 1651, 1812, 1884, 489, 387, 1900, 1648, 884, 1676, 1097, 1567, 949, 737, 1743, 548, 324, 251, 1693, 41, 663, 1039, 1507, 1754, 1351, 905, 915, 1750, 741, 1076, 1938, 460, 1183, 729, 1987, 987, 1055, 481, 795, 603, 1199, 19, 1719, 311, 86, 1501, 1434, 618, 1876, 1990, 742, 1894, 1129, 1197, 123, 800, 1935, 222, 1091, 1950, 953, 1908, 130, 658, 652, 478, 1745, 1677, 1651, 33, 1027, 1493, 253, 1925, 1523, 489, 1098, 1066, 128, 999, 1852, 178, 1850, 985, 1662, 338, 1078, 251, 1945, 894, 1637, 1446, 1738, 327, 401, 1149, 1556, 523, 1971, 1341, 2000, 196, 161, 1688, 1942, 3, 1371, 1403, 601, 1300, 1855, 812, 549, 938, 87, 1473, 1084, 868, 1171, 242, 1335, 1521, 1193, 1920, 1951, 1948, 1926, 484, 751, 1253, 1813, 296, 910, 192, 1002, 1467, 1548, 1652, 933, 270, 1719, 612, 1243, 1425, 1961, 226, 2, 1639, 1856, 37, 1072, 1438, 1428, 1557, 1679, 963, 1343, 830, 1818, 1027, 792, 1123, 1444, 191, 358, 988, 1367, 833]))
30
+
31
+ test7 :: Test
32
+ test7 = TestCase (assertEqual "for (countCompleteSubarrays [1490, 1499, 1262, 1043, 937, 1062, 550, 1579, 866, 1878, 902, 642, 1501, 1325, 896, 520, 736, 1502, 1405, 577, 1075, 778, 1308, 961, 1744, 1583, 504, 1861, 453, 1060, 1656, 1689, 159, 1865, 568, 353, 806, 206, 380])," 1 (countCompleteSubarrays [1490, 1499, 1262, 1043, 937, 1062, 550, 1579, 866, 1878, 902, 642, 1501, 1325, 896, 520, 736, 1502, 1405, 577, 1075, 778, 1308, 961, 1744, 1583, 504, 1861, 453, 1060, 1656, 1689, 159, 1865, 568, 353, 806, 206, 380]))
33
+
34
+
35
+ -- Grouping test cases
36
+ tests :: Test
37
+ tests = TestList [TestLabel "Test1" test1, TestLabel "Test2" test2, TestLabel "Test3" test3, TestLabel "Test4" test4, TestLabel "Test5" test5, TestLabel "Test6" test6]
38
+
39
+ -- Running the tests
40
+ main :: IO Counts
41
+ main = runTestTT tests
count_complete_subarrays_in_an_array/java_tests/Main.java ADDED
@@ -0,0 +1,20 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ import static org.junit.jupiter.api.Assertions.*;
3
+ import org.junit.jupiter.api.Test;
4
+ import java.util.List;
5
+ import java.util.Arrays;
6
+ public class Main {
7
+ //Program start
8
+
9
+ //Program end
10
+
11
+ @Test
12
+ public void test1() {
13
+ assertEquals(4, countCompleteSubarrays(Arrays.asList(1,3,1,2,2)));
14
+ }
15
+ @Test
16
+ public void test2() {
17
+ assertEquals(10, countCompleteSubarrays(Arrays.asList(5,5,5,5)));
18
+ }
19
+
20
+ }