Merhabalar ben Erasmus'ta olan bir öğrenciyim ve burada bir ders içeriğinde Haskell görüyoruz ve hocamız bize bir ödev verdi.

The definition of a binary tree has the form:

data Tree a = Leaf a
             | Node a (Tree a) (Tree a)
             | null
Enter the implementation of the equal function checking whether the two binary trees are identical.

Tip
equal :: Eq a => Tree a -> Tree a -> Bool
equal Null Null = {- ... -}
equal {- ... -} = a == b
equal (Node a1 left1 right1) {- ... -} = a1 == a2 && {- ... -}
equal _ _ = False
In the above outline of implementation, replace comments {- ... -} into the appropriate code.
Bu kodu aşağıdaki hale getirdim ama bir türlü equal {- ... -} = a == b kısmını bulamadım. Bilen varsa acaba yardım edebilir mi?
equal :: Eq a => Tree a -> Tree a -> Bool
equal Null Null = True
equal {- ... -} = a == b
equal (Node a1 left1 right1) (Node a2 left2 right2) = a1 == a2 && equal left1 right2 && equal right1 left2
equal _ _ = False