Haskellをラクガク

2006-09-10第3章

3.6 練習問題 00:59

main = do   cs <- getContents
            putStr $ concat $ map swapa cs

swapa 'a' = ['A']
swapa 'A' = ['a']
swapa c = [c]
>swapa < swapa.hs
mAin = do   cs <- getContents
            putStr $ concAt $ mAp swApA cs

swApA 'A' = ['a']
swApA 'a' = ['A']
swApA c = [c]

できたはできたけど、答えをみたらswapaの結果をわざわざリストで返す必要はないらしい。そっか、Char -> Charだから、

map swapa cs

の結果はCharリスト、すなわち文字列ってことか。

感想 00:59

JitendraJitendra 2013/03/31 19:08 You got to push it-this essenital info that is!

mtvaruskmtvarusk 2013/04/01 18:43 Deq8yX <a href="http://skhinelwwzmf.com/">skhinelwwzmf</a>

phohdkphohdk 2013/04/02 08:00 ubDOK6 <a href="http://eztuvogqcylk.com/">eztuvogqcylk</a>

atvombgxmvhatvombgxmvh 2013/04/04 19:36 JlTRKD , [url=http://jnsvmvqssnqo.com/]jnsvmvqssnqo[/url], [link=http://bkmypnftmjxj.com/]bkmypnftmjxj[/link], http://voeqapkvfjqy.com/

JooceenaveJooceenave 2018/10/27 21:24 online casino slots
<a href=http://playslotscasino888.com/>new usa online casinos 2017</a>
pogo casino slots
<a href="http://playslotscasino888.com/">best us casinos online</a>
pogo casino slots

CarsenTopCarsenTop 2018/10/27 23:30 free casino games and poker
<a href=http://playslotscasino888.com/>casino games slots</a>
vegas casino games
<a href="http://playslotscasino888.com/">casino games real money</a>
casino games free

JooceenaveJooceenave 2018/10/29 01:11 online casinos 2016
<a href=http://playslotscasino888.com/>new usa online casinos</a>
online casino
<a href="http://playslotscasino888.com/">casino online gambling</a>
best us casinos online

MofgyLoafeMofgyLoafe 2018/10/30 17:35 casino online usa
<a href=http://gamecasinosonline.com/>play casinos</a>
play casino games online
<a href="http://gamecasinosonline.com/">casino online application</a>
pogo casino slots

LasriKagLasriKag 2018/10/30 20:13 online casino
<a href=http://casinousaonlinelist.com/>free casino games and poker</a>
online casino real money
<a href="http://casinousaonlinelist.com/">casino g</a>
online casinos 2016

LasriKagLasriKag 2018/11/01 14:53 vegas casino games
<a href=http://casinousaonlinelist.com/>play casino games online</a>
online casinos 2016
<a href="http://casinousaonlinelist.com/">casino online free</a>
casino online usa

MofgyLoafeMofgyLoafe 2018/11/02 09:38 casino games free online
<a href=http://gamecasinosonline.com/>online casinos 2016</a>
best us casinos online
<a href="http://gamecasinosonline.com/">casino online free</a>
casino online free

BeulahwristBeulahwrist 2018/11/02 17:57 seneca niagara casino
<a href=http://traditionzonecasino.com/>chumba casino login</a>
sugarhouse online casino nj
<a href="http://traditionzonecasino.com/">sandia casino</a>
hollywood casino free slots online

DaisymupDaisymup 2018/11/02 20:20 onlinecasinos
<a href=http://trustzonecasino.com/>downstream casino</a>
doubledown casino promo codes forum
<a href="http://trustzonecasino.com/">olg online casino</a>
hollywood casino games free

JooceenaveJooceenave 2018/11/03 22:50 casinos online
<a href=http://playslotscasino888.com/>free casino games and poker</a>
online casino real money
<a href="http://playslotscasino888.com/">casino games roulette</a>
online casino real money

CarsenTopCarsenTop 2018/11/04 01:19 online casino
<a href=http://playslotscasino888.com/>casino games free</a>
casino games free online
<a href="http://playslotscasino888.com/">casino g</a>
casino games list

ChbriCizChbriCiz 2018/11/06 08:02 new usa online casinos
<a href=http://slotsmegacasino.com/>vegas casino games</a>
new usa online casinos 2017
<a href="http://slotsmegacasino.com/">casino games roulette</a>
best online casino games free

MonitaGeshyMonitaGeshy 2018/11/16 19:42 casino games
<a href=http://gamecasinosonline.com/>play casinos</a>
play casino games online
<a href="http://gamecasinosonline.com/">play casino games online</a>
online casino

NatshaDigNatshaDig 2018/11/18 21:17 casino g
<a href=http://trustzonecasino.com/>casino online for fun</a>
casino online for fun
<a href="http://trustzonecasino.com/">casino games</a>
casino games list

MonitaGeshyMonitaGeshy 2018/11/19 11:49 vegas casino games
<a href=http://gamecasinosonline.com/>casino online gambling</a>
play casinos
<a href="http://gamecasinosonline.com/">casino online gambling</a>
casino games real money

MonitaGeshyMonitaGeshy 2018/11/21 02:09 play casino games online
<a href=http://gamecasinosonline.com/>online casino</a>
casino games slots
<a href="http://gamecasinosonline.com/">casino games free online</a>
casino games roulette

TempliemopTempliemop 2018/11/21 17:50 top rated free online casino games
<a href=http://gamecasinosonline.com/>casino games slots</a>
best online casino games free
<a href="http://gamecasinosonline.com/">casino games free</a>
casinos online

YvouneSmedyYvouneSmedy 2018/11/24 21:48 play casino games online
<a href=http://gamecasinosonline.com/>casino online for fun</a>
casino games real money
<a href="http://gamecasinosonline.com/">casino online application</a>
casino games free

ゲスト



トラックバック - http://haskell.g.hatena.ne.jp/hsyd/20060910