Write a Haskell function that generates all binary trees with empty leaves of size n

Zrušen Zveřejněno před 7 lety K zaplacení v momentě doručení
Zrušen K zaplacení v momentě doručení

Write a Haskell function that generates all binary trees with empty leaves of size n.

Then, given a binary tree, write a function that counts the number of leaves and another function that the number of internal nodes.

What do you observe about the two results? Write a short proof by induction as a comment added to your program stating that your observation applies to binary trees of any size.

The uploaded file is a similar concept of what the function should be like.

Haskell Programování

Identifikační číslo projektu: #12960515

O projektu

3 nabídek Projekt na dálku Aktivní před 7 lety

3 Freelnceři na tento projekt zveřejňují nabídky v průměru $73

ahmsak

Hello Sir, I am a computer science tutor, I teach (among others) Haskell, Scheme, LISP, Prolog and Algorithms. I have done many projects like this, and I'm one of the top Haskell developers, and you can check by cli Další

$90 USD za 1 den
(60 Recenzí)
6.1
iitmshanker

Hello, I have been working in AI, Machine Learning and computer vision for last 2-3 years. I have done 6-7 projects on freelancer in last 2 months in those areas. I have worked with following python libraries: NLT Další

$100 USD za 2 dní
(2 Recenzí)
2.6
ArtyMcLabin

hey, what do you mean by empty binary trees? can you please supply an example of desired input and output? :)

$30 USD za 1 den
(0 Recenzí)
0.0