Home

About

Advanced Search

Browse by Discipline

Scientific Societies

E-print Alerts

Add E-prints

E-print Network
FAQHELPSITE MAPCONTACT US


  Advanced Search  

 
First name Last name Matriculation number Exercise 1 (2+2+2 points)
 

Summary: First name Last name Matriculation number
1
Exercise 1 (2+2+2 points)
The following data structure represents binary trees only containing values at the leaves:
data Tree a = Node (Tree a) (Tree a) | Leaf a
Consider the tree t of integers on the right­hand
side. The representation of t as an object of type
Tree Int in Haskell would be:
Node (Node (Leaf 1) (Leaf 2)) (Leaf 3)
·
#
#
#
#
#
#
#
#
# # # # # # # #
·

  

Source: Ábrahám, Erika - Fachgruppe Informatik, Rheinisch Westfälische Technische Hochschule Aachen (RWTH)

 

Collections: Computer Technologies and Information Sciences