3. é¢æ°ãå®ç¾©ãã ãã®æç« ã§ã¯ Haskell ã§é¢æ°ãå®ç¾©ããæ¹æ³ã«ã¤ãã¦è¿°ã¹ã¾ãã 1. = ã¯é¢æ°å®ç¾© Haskell ã«ã¯ä»£å ¥ãç¡ãã®ã§ã= ãé¢æ°å®ç¾©ã«ä½¿ãã¾ãã foo x y = x + y hoge = 2 foo ã¯ï¼ã¤ã®å¼æ°ãåã£ã¦ããããã®åãè¿ãé¢æ°ã§ããä¸æ¹ã hoge ã¯å¼æ°ãåããã常㫠2 ãè¿ãå®æ°é¢æ°ã§ãã ãããããã¡ã¤ã«ï¼ä¾ãã° a.hs)ã«æ¸ããã®ã¡ãã¼ãããã¨æ¬¡ã®ããã«ãªãã¾ãã Prelude> :l a.hs Main> foo 1 2 3 Main> hoge 2 ã¡ãªã¿ã«ããã³ããã«ã¯ hugs ãæå¾ã«èªã¿è¾¼ãã ã¢ã¸ã¥ã¼ã«åã表示ããã¾ãã hugs ãç«ã¡ä¸ããã¨ã Prelude ã¨ããã¢ã¸ã¥ã¼ã«ãèªã¿è¾¼ã¾ããã®ã§è¡¨ç¤ºã Prelude ã«ãªã£ã¦ãã¾ããä¸æ¹ãa.hs ãèªã¿è¾¼ã㨠Main ã«ãªãã®ã¯ã ã¢ã¸ã¥ã¼ã«åãçç¥ãã
{{#tags}}- {{label}}
{{/tags}}