-- Testfaelle Aufgabenblatt 9 test_all = and [t1a_t1, t1b_t1, t1c_t1, t2a_t1, t2a_t2, t2a_t3, t2b_t1, t2b_t2, t2c_t1, t2c_t2, t2d_t1, t2d_t2, t2e_t1, t2e_t2] t1a_t1 = (Main.maximum $ take 700 $ cycle [1,6..13337]) == 3496 t1b_t1 = primes (2,25) == [2,3,5,7,11,13,17,19,23] t1c_tree = Node 11 (Node 21 (Node 31 Nil Nil) (Node 32 (Node 41 Nil Nil) Nil)) Nil t1c_t1 = nodes t1c_tree == 5 t2a_t1 = isValid [1, 50, 30, 10, 40, 20, 3] == True t2a_t2 = isValid [2, 50, 30, 10, 40, 20, 3] == False t2a_t3 = isValid [1, 60, 30, 10, 40, 20, 3] == False t2b_t1 = computeVisibility [50, 30, 10, 40, 20] == [1, 50, 30, 10, 40, 20, 3] t2b_t2 = computeVisibility [10,20..50] == 5:[10,20..50]++[1] -- Beachten Sie, dass das Resultat i.a. nicht eindeutig festgelegt ist t2c_t1 = buildSkyscrapers 5 1 5 == Just [1,50,40,30,20,10,5] t2c_t2 = buildSkyscrapers 5 5 5 == Nothing t2d_t1 = noOfSkyscraperLines 4 2 2 == 6 t2d_t2 = noOfSkyscraperLines 5 5 5 == 0 t2e_t1 = allSkyscraperLines 5 1 5 == [[1,50,40,30,20,10,5]] t2e_t2 = allSkyscraperLines 4 2 2 == [[2,10,40,20,30,2],[2,20,10,40,30,2],[2,20,40,10,30,2],[2,30,10,40,20,2],[2,30,20,40,10,2],[2,30,40,10,20,2]]