Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jackfoxy/funcpatterndemosolution
Working with Functional Data Structures, Practical F# Application -- companion demos
https://github.com/jackfoxy/funcpatterndemosolution
Last synced: about 17 hours ago
JSON representation
Working with Functional Data Structures, Practical F# Application -- companion demos
- Host: GitHub
- URL: https://github.com/jackfoxy/funcpatterndemosolution
- Owner: jackfoxy
- License: other
- Created: 2012-10-05T16:56:20.000Z (about 12 years ago)
- Default Branch: master
- Last Pushed: 2013-08-04T20:02:07.000Z (over 11 years ago)
- Last Synced: 2023-03-24T18:37:12.433Z (over 1 year ago)
- Language: F#
- Size: 6.5 MB
- Stars: 2
- Watchers: 1
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
- License: LICENSE.md
Awesome Lists containing this project
README
Companion demonstration for [Working with Functional Data Structures, Practical F# Application](http://www.siliconvalley-codecamp.com/Sessions.aspx?ForceSortBySessionTime=true&AttendeeId=8689) at Silicon Valley Code Camp 2012.
#Demo1
1) Recursing through a list with active pattern to format the data according to Eric Lippert's "Comma Quibbling".
2) Doing the same with a LazyList takes more time and more Garbage Collection.
3) But if active pattern cuts short recursion before covering the whole list LazyList actually saves resources (time).(Especially useful if calculation or other resources involved.)
#Demo2
1) Demonstrate bifurcating a heap by referencing its internal structure.
2) Demonstrate counting elements faster than O(n).
3) Remove inexed item by re-shaping structure to structure that supports remove.
#Demo3
Create RandomStack data structure that internally implements 2 parts:
1) IComparable type consisting of a random integer and value.
2) Heap of the IComparable items.