Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Why Haskell can save your life

Why Haskell can save your life

Slides for a lightning talk on Haskell:
- examples of how expensive software bugs could be
- why having a bug in your application could be fatal
- why is Haskell good at eliminating bugs

lenkodonchev

May 07, 2016
Tweet

More Decks by lenkodonchev

Other Decks in Programming

Transcript

  1. Why Haskell can save your life?

  2. What is the cost of software errors?

  3. NASA’s Mars Climate Orbiter A Bug = $327 Million

  4. EDS Child Support System A Bug = $440 Million

  5. The Intel’s Pentium bug

  6. Intel has given Pentium BUG key chains as gifts to

    the employees to remind them how expensive a BUG could be.
  7. Ariane 5 rocket self destruction A Bug = $370 Million

  8. Knight Capital Trading Glitch $440 Million

  9. Software bugs cost the US economy $59.5 billion every year.

  10. This is your manager when you have introduced a million

    dollar bug...
  11. The Big Boss after you have introduced a million dollar

    bug...
  12. What happens to a developer with a million dollar bug?

  13. DEVELOPER

  14. Why Haskell is going to save your life?

  15. Haskell is a functional programming language that will open your

    mind for a new way of thinking. Haskell will expand your vision and will make you a better developer.
  16. Haskell is like the summer rain - it will clear

    your mind of all non-functionall impurities.
  17. None
  18. Why learning Haskell is good for you?

  19. It is highly unlikely that you will find a job

    doing Haskell. BUT learning Haskell will make you a better developer.
  20. Why is Haskell good at eliminating BUGS ?

  21. Bug Eliminator #1 Static typing

  22. Static typing gives earlier feedback on whether or not the

    code meets the requirements that can be expressed by the type system.
  23. Bug Eliminator #2 Sophisticated type system

  24. Haskell’s type checker catches most of the bugs that happen

    at runtime in other languages.
  25. The Maybe type in Haskell: data Maybe a = Nothing

    | Just a
  26. Bug Eliminator #3 Immutability

  27. Haskell is a pure functional programming language and state and

    side effects are modeled using “Monads”.
  28. None
  29. None
  30. Bug Eliminator #4 Isolation

  31. In Haskell Monads are used to create imperative style computational

    structures which remain isolated from the main body of the functional program.
  32. A function to read from a file using the IO

    monad readFile :: FilePath -> IO String
  33. Bug Eliminator #5 Property based testing

  34. Haskell has excellent support for property based testing implemented in

    the QuickCheck library.
  35. Learn Haskell (It may save your life)