{"id":13484324,"url":"https://github.com/IHaskell/learn-you-a-haskell-notebook","last_synced_at":"2025-03-27T16:30:44.260Z","repository":{"id":38328729,"uuid":"193663504","full_name":"IHaskell/learn-you-a-haskell-notebook","owner":"IHaskell","description":"Jupyter adaptation of Learn You a Haskell for Great Good!","archived":false,"fork":false,"pushed_at":"2023-10-23T02:19:52.000Z","size":2596,"stargazers_count":296,"open_issues_count":5,"forks_count":48,"subscribers_count":8,"default_branch":"master","last_synced_at":"2024-10-30T18:42:32.368Z","etag":null,"topics":["haskell","haskell-book","haskell-learning","haskell-tutorial","jupyter","jupyter-notebook","learn-you-a-haskell"],"latest_commit_sha":null,"homepage":"","language":"Jupyter Notebook","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/IHaskell.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2019-06-25T08:07:32.000Z","updated_at":"2024-10-21T15:27:16.000Z","dependencies_parsed_at":"2023-01-23T00:31:19.791Z","dependency_job_id":"de52dbac-aecb-4c1a-a618-91ce10353eec","html_url":"https://github.com/IHaskell/learn-you-a-haskell-notebook","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/IHaskell%2Flearn-you-a-haskell-notebook","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/IHaskell%2Flearn-you-a-haskell-notebook/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/IHaskell%2Flearn-you-a-haskell-notebook/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/IHaskell%2Flearn-you-a-haskell-notebook/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/IHaskell","download_url":"https://codeload.github.com/IHaskell/learn-you-a-haskell-notebook/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245882223,"owners_count":20687853,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["haskell","haskell-book","haskell-learning","haskell-tutorial","jupyter","jupyter-notebook","learn-you-a-haskell"],"created_at":"2024-07-31T17:01:22.550Z","updated_at":"2025-03-27T16:30:41.604Z","avatar_url":"https://github.com/IHaskell.png","language":"Jupyter Notebook","funding_links":[],"categories":["Jupyter Notebook"],"sub_categories":[],"readme":"# Learn You a Haskell for Great Good!\n\nRead the book right now on __mybinder.org__ with this link: [![launch Learn You a Haskell for Great Good!](https://img.shields.io/badge/launch-Learn%20You%20A%20Haskell%20For%20Great%20Good!-579ACA.svg?logo=data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAFkAAABZCAMAAABi1XidAAAB8lBMVEX///9XmsrmZYH1olJXmsr1olJXmsrmZYH1olJXmsr1olJXmsrmZYH1olL1olJXmsr1olJXmsrmZYH1olL1olJXmsrmZYH1olJXmsr1olL1olJXmsrmZYH1olL1olJXmsrmZYH1olL1olL0nFf1olJXmsrmZYH1olJXmsq8dZb1olJXmsrmZYH1olJXmspXmspXmsr1olL1olJXmsrmZYH1olJXmsr1olL1olJXmsrmZYH1olL1olLeaIVXmsrmZYH1olL1olL1olJXmsrmZYH1olLna31Xmsr1olJXmsr1olJXmsrmZYH1olLqoVr1olJXmsr1olJXmsrmZYH1olL1olKkfaPobXvviGabgadXmsqThKuofKHmZ4Dobnr1olJXmsr1olJXmspXmsr1olJ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xkaLiqQb+kGduJTNHG72zcW9LoJgqQxpP3/Tj//c3yB0tqzaml05/+orHLksVO+95kX7/7qgJvnjlrfr2Ggsyx0eoy9uPzN5SPd86aXggOsEKW2Prz7du3VID3/tzs/sSRs2w7ovVHKtjrX2pd7ZMlTxAYfBAL9jiDwfLkq55Tm7ifhMlTGPyCAs7RFRhn47JnlcB9RM5T97ASuZXIcVNuUDIndpDbdsfrqsOppeXl5Y+XVKdjFCTh+zGaVuj0d9zy05PPK3QzBamxdwtTCrzyg/2Rvf2EstUjordGwa/kx9mSJLr8mLLtCW8HHGJc2R5hS219IiF6PnTusOqcMl57gm0Z8kanKMAQg0qSyuZfn7zItsbGyO9QlnxY0eCuD1XL2ys/MsrQhltE7Ug0uFOzufJFE2PxBo/YAx8XPPdDwWN0MrDRYIZF0mSMKCNHgaIVFoBbNoLJ7tEQDKxGF0kcLQimojCZopv0OkNOyWCCg9XMVAi7ARJzQdM2QUh0gmBozjc3Skg6dSBRqDGYSUOu66Zg+I2fNZs/M3/f/Grl/XnyF1Gw3VKCez0PN5IUfFLqvgUN4C0qNqYs5YhPL+aVZYDE4IpUk57oSFnJm4FyCqqOE0jhY2SMyLFoo56zyo6becOS5UVDdj7Vih0zp+tcMhwRpBeLyqtIjlJKAIZSbI8SGSF3k0pA3mR5tHuwPFoa7N7reoq2bqCsAk1HqCu5uvI1n6JuRXI+S1Mco54YmYTwcn6Aeic+kssXi8XpXC4V3t7/ADuTNKaQJdScAAAAAElFTkSuQmCC)](https://mybinder.org/v2/gh/IHaskell/learn-you-a-haskell-notebook/master?urlpath=lab/tree/learn_you_a_haskell/00-preface.ipynb)\n(Usually takes a minute to launch)\n\n---\n\n![Screenshot](README.screenshot.png)\n\nThis is a Jupyter notebook adaptation of the book [__*Learn You a Haskell for Great Good!*__](http://learnyouahaskell.com/) by Miran Lipovača.\n\nI learned Haskell from this book in 2014 by following along in [GHCI](https://downloads.haskell.org/~ghc/latest/docs/html/users_guide/ghci.html), as the book suggested.\n\nIn 2019, the [Jupyter](https://jupyter.org/) notebook format would be a nice way read this book. This is one of the best cases for Theodore Gray's idea of the [computational essay](https://www.theatlantic.com/science/archive/2018/04/the-scientific-paper-is-obsolete/556676/), and Andrew Gibiansky has made it possible with [IHaskell](https://github.com/IHaskell/IHaskell).\n\nEach chapter of the book is one `.ipynb` Jupyter notebook file. See the list of chapter files on the left sidebar in JupyterLab.\n\nEach notebook cell depends on cells that come before it, so run the notebooks from top to bottom. I have refactored code to make the examples work in Jupyter, and removed instructions for how to use GHCI. Other than that I have tried to be faithful to the original text.\n\nMiran Lipovača wrote this book and released it to the world under a [Creative Commons Attribution-Noncommercial-Share Alike 3.0 Unported License](http://creativecommons.org/licenses/by-nc-sa/3.0/), which means that the book is free-as-in-speech, and allows us to enjoy the book in notebook format. But that does not mean that the book is free-as-in-beer; it means that you, dear reader, pay for the book under the honor system. If you are honorable and you want to keep living in a world in which honorable artists license their art as Creative Commons, then [buy the book](http://learnyouahaskell.com/).\n\nThanks also to Paul Vorbach for \u003chttps://github.com/pvorb/learn-you-a-haskell\u003e.\n\n# How to run on your local computer in Visual Studio Code\n\nVisual Studio Code has a\n[Notebook UI](https://code.visualstudio.com/docs/datascience/jupyter-notebooks)\nwhich you can use to run Jupyter kernels instead of the browser-based\nJupyterLab or classic Jupyter UI.\n\nClone this repository with `git` and `cd` into the cloned directory\n\n```bash\ngit clone https://github.com/IHaskell/learn-you-a-haskell-notebook.git\ncd learn-you-a-haskell-notebook\ncode .\n```\n\nThere is a Docker\n[Visual Studio Code devcontainer](https://github.com/microsoft/vscode-dev-containers)\nconfiguration in the [`.devcontainer`](.devcontainer) directory.\n\nWhen you open Visual Studio Code by running `code .`, a pop-up dialog will\ntell you that “Folder contains a Dev Container configuration file. Reopen folder\nto develop in a container.” Click the button labelled __Reopen in Container__.\n\nYou will then be able to open the `.ipynb` chapter files in the `notebook`\ndirectory.\n\n# How to run on your local computer in JupyterLab in a web browser\n\nClone this repository with `git` and `cd` into the cloned directory\n\n```bash\ngit clone https://github.com/IHaskell/learn-you-a-haskell-notebook.git\ncd learn-you-a-haskell-notebook\n```\n\nThen here are three options for running.\n\n1. `docker`\n\n   ```bash\n   docker run --rm -p 8888:8888 -v $PWD/notebook:/home/jovyan/work --name learn-you-a-haskell ghcr.io/ihaskell/ihaskell-notebook:master jupyter lab --ServerApp.token=''\n   ```\n\n   then open [http://localhost:8888](http://localhost:8888) to read the book.\n\n2. `podman`\n\n   ```bash\n   podman run --privileged --userns=keep-id --rm -p 8888:8888 -v $PWD/notebook:/home/jovyan/work --name learn-you-a-haskell ghcr.io/ihaskell/ihaskell-notebook:master jupyter lab --ServerApp.token=''\n   ```\n\n   then open [http://localhost:8888](http://localhost:8888) to read the book.\n\n3. [NixOS](https://nixos.org/) flake\n\n   ```\n   nix run . -- --notebook-dir notebook\n   ```\n\n   then the book will open in a browser automatically. If it doesn’t, open the “running at” link.\n\n# How to edit notebooks\n\nIf you make an improvement to a notebook `.ipynb` file and you want to save the file and commit the changes and make a pull request to the repository,\n\n1. Maximize the browser window to full screen width, because cell horizontal scroll bar visibility gets saved in the notebook.\n\n2. Run -\u003e Restart kernel and Run All Cells...\n\n3. Save the notebook.\n\n# ihaskell-notebook\n\nFor more information about the IHaskell Docker image, see \u003chttps://github.com/IHaskell/ihaskell-notebook\u003e\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FIHaskell%2Flearn-you-a-haskell-notebook","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FIHaskell%2Flearn-you-a-haskell-notebook","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FIHaskell%2Flearn-you-a-haskell-notebook/lists"}