Haskell - Tutorial 1 - GHC and Cabal

Поделиться
HTML-код
  • Опубликовано: 8 янв 2025

Комментарии • 30

  • @ivelten
    @ivelten 2 года назад

    I've been looking for a guide like this for Haskell in a long time. Thank you very much for it.

  • @eugeniogonzato
    @eugeniogonzato 3 года назад +10

    Please zoom your screen its impossibile to read

  • @xyzrealestate5217
    @xyzrealestate5217 3 года назад +2

    Thank you a lot for the tutorials! I totally mean it. You helped me a lot and you also explain great. keep going

  • @bernardo5733
    @bernardo5733 3 года назад +1

    Great tutorial, you really wiped out my doubts. Keep going Bro, you have all thumbs up from now on

  • @slentzen
    @slentzen 4 года назад

    I completely agree to what you're saying, there's a gap in Haskell tutorials that takes you from zero to type level programming

    • @jameshobson6965
      @jameshobson6965  4 года назад

      I hope I fill the gap with my tutorials. But if mine are a bit too rubbish, I hope at least someone learns that there is a need for the gap to be filled and makes some better ones 😂

  • @mimosveta
    @mimosveta 3 года назад +4

    ugh, the a, the terminal, it's too small, i have a huge screen and am blind as a bat, so I'm just guessing what you're typing there :S

    • @jameshobson6965
      @jameshobson6965  3 года назад

      Apologies. There is slow increase in text size as the tutorials progress

  • @org.photonsphere
    @org.photonsphere 3 года назад +1

    I've recently found this cabal command: list-bin list path to a single executable

    • @jameshobson6965
      @jameshobson6965  2 года назад

      I did not know that! That is so unbelievably useful!

  • @JohnWick-mk4ve
    @JohnWick-mk4ve 2 года назад

    Hi.. Thanks for this. Can u also show how u have configured ur ide or post a link to it.. Larger font sizd would also help

    • @jameshobson6965
      @jameshobson6965  2 года назад

      I use SpaceVim with neovim. I have customised it a little, but not in any way that is obvious from the tutorials

  • @lool7922
    @lool7922 3 года назад +1

    nice explanation,
    could you please explain the meaning of this function, would be great if you put some examples?
    numberWang : : (Num n, Show n, Ord n) => n -> String

    • @jameshobson6965
      @jameshobson6965  3 года назад +2

      Wow. I mean we weren't going to cover numberwang until tutorial 42! But I'll give you a little spoiler:
      numberWang -3.443 = "Thats Numberwang!"

    • @lool7922
      @lool7922 3 года назад

      @@jameshobson6965 is it possible to help me with my projects? I am happy to keep watching your videos but my projects have different deadlines.

    • @jameshobson6965
      @jameshobson6965  3 года назад +2

      Well my policy is, you can ask any question in the RUclips comments. If you just dump an entire question from your assignment, it's unlikely that you will get anything useful from me. That forces you to do the thinking! Learning is hard!

    • @lool7922
      @lool7922 3 года назад

      @@jameshobson6965you are completely right, “learning is hard” but I’m taking this course as an elective course. I actually don’t need to learn Haskell, however Haskell is a great programming language. Unfortunately, it’s is not going to help me after graduation as I’m majoring in business management. I hope you got what I mean. Will you consider helping me for -> $$. Business is business

  • @sebastianaguerre9064
    @sebastianaguerre9064 2 года назад

    what interpreter ar you using ? were you have ur code

    • @jameshobson6965
      @jameshobson6965  2 года назад

      - GHCi as interpreter
      - spaceVIM with neovim as editor
      - iTerm2 as terminal emulator

  • @rubenkaller4788
    @rubenkaller4788 3 года назад

    Hi I'm on arch and ghc is dynamic here. How do I link dynamic with cabal?

    • @jameshobson6965
      @jameshobson6965  3 года назад

      --enable-executable-dynamic I think?

    • @jameshobson6965
      @jameshobson6965  3 года назад

      But I wouldn't do that! Good Packaging practice is, get the source to build in the most easy way. Don't bother pacman just yet! Then, when you are done, you can use whatever packaging tools are used on arch to get it linking to the packages

    • @jameshobson6965
      @jameshobson6965  3 года назад

      Also, I understand your question now! if you use pacman to install a ghc library, cabal should just use that one. It's a really good way of breaking everything though so that's a warning! I can go into packaging practice if that's an aim of yours. If not, just use cabal's offering

    • @rubenkaller4788
      @rubenkaller4788 3 года назад

      @@jameshobson6965 Thanks for your quick reply. What I meant was that I can run the cabal project with >>>ghc -dynamic src-exe/Main.hs but with >>>cabal run i get the error
      Could not find module ‘Prelude’
      There are files missing in the ‘base-4.14.1.0’ package
      after some googling I found out that the standard haskell libs on arch are dynamic libs. I am brand new to this stuff. So I dont know how to explain properly. Any help is appreciated. I was looking for a -dynamic flag inside the cabal config file

    • @rubenkaller4788
      @rubenkaller4788 3 года назад

      @@jameshobson6965 Also thanks for the solid tutorials looks better then most :)

  • @estebanmanaricua9753
    @estebanmanaricua9753 4 года назад

    thank you for this