Skip to content
/ fp-exercises Public template

Implement your own functional programming library in JavaScript.

License

Notifications You must be signed in to change notification settings

djizco/fp-exercises

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Functional Programming Exercises

Getting Started

  • Requires node version 10.0.0 or higher.
npm install

Implement each function in the following order. Avoid using native JavaScript implementations when possible.

When you begin working on a problem, you can enable the tests with the command:

npm run enable [problem]

and enable the challenge mode with the command:

npm run enable:challenge [problem]

The function is complete when all tests are passing. To run the test suite enter the command:

npm test
# or
npm test:watch

Part I: Mathematics

  • add
  • subtract
  • inc
  • dec
  • multiply
  • divide
  • negate
  • max
  • min

Part II: Iteration

  • each
  • filter
  • reject
  • keys
  • pick
  • concat
  • append
  • reverse

Part III: Reduction

  • reduce
  • sum
  • product
  • mean
  • join
  • identity
  • all
  • any
  • none
  • find
  • equals
  • indexOf
  • includes
  • uniq

Part IV: Manipulation

  • map
  • pluck
  • merge
  • assoc
  • slice
  • head
  • tail
  • first
  • last
  • take
  • drop
  • takeLast
  • dropLast

Part V: Functions

  • bind
  • tap
  • once
  • delay
  • pickBy
  • pipe
  • partial
  • curry

Part VI: Challenge

  • median
  • groupBy
  • throttle
  • memoize
  • shuffle
  • zip
  • flatten
  • intersection
  • difference
  • split
  • equals (challenge)
  • indexOf (challenge)
  • includes (challenge)

About

Implement your own functional programming library in JavaScript.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published