Home freenode/#haskell: Logs Calendar

Logs: freenode/#haskell

←Prev  Next→ 502,152 events total
2020-11-09 00:52:25 × m0rphism quits (~m0rphism@HSI-KBW-095-208-098-207.hsi5.kabel-badenwuerttemberg.de) (Ping timeout: 264 seconds)
2020-11-09 00:52:58 × _ashbreeze_ quits (~mark@72-161-252-32.dyn.centurytel.net) (Ping timeout: 260 seconds)
2020-11-09 00:55:08 litenull joins (~litenull@s91904426.blix.com)
2020-11-09 00:56:04 elliott_ joins (~elliott_@pool-108-51-141-12.washdc.fios.verizon.net)
2020-11-09 00:56:09 Varis joins (~Tadas@unaffiliated/varis)
2020-11-09 00:56:21 Echosolace joins (99ec1b94@p1276149-omed01.tokyo.ocn.ne.jp)
2020-11-09 00:57:39 <Echosolace> Hey all, I'm still plodding along through learn you a haskell and I have a question about the groupby function, specifically, why the group by function is grouping together more than just pairs of items. Does anyone know why the following works out as it does?
2020-11-09 00:57:44 <Echosolace> let values = [-4.3, -2.4, -1.2, 0.4, 2.3, 5.9, 10.5, 29.1, 5.3, -2.4, -14.5, 2.9, 2.3]
2020-11-09 00:57:59 <Echosolace> groupBy (\x y -> (x > 0) == (y > 0)) values
2020-11-09 00:58:08 <Echosolace> [[-4.3,-2.4,-1.2],[0.4,2.3,5.9,10.5,29.1,5.3],[-2.4,-14.5],[2.9,2.3]]
2020-11-09 00:58:56 × Feuermagier quits (~Feuermagi@213.178.26.41) (Ping timeout: 256 seconds)
2020-11-09 00:59:00 <Axman6> Echosolace: groupBy is notoriously confusing, it groups runs of values together when _the first_ element combined with the others return true
2020-11-09 00:59:33 <Axman6> > groupBy (\x y -> y > x) [1,2,3,4,3,2,3,2,1,2,3,2,1]
2020-11-09 00:59:35 <lambdabot> [[1,2,3,4,3,2,3,2],[1,2,3,2],[1]]
2020-11-09 01:00:09 <Echosolace> That's comforting to hear. Let me try to understand that.
2020-11-09 01:00:10 <Echosolace> Thanks.
2020-11-09 01:00:19 × nbloomf quits (~nbloomf@2600:1700:ad14:3020:a17b:c481:d5f1:9100) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-11-09 01:00:49 <Axman6> it's basicallt a repeated use of: case xs of (y:ys?) -> takeWhile (f y) ys
2020-11-09 01:00:57 <Axman6> without the typos...
2020-11-09 01:04:36 nbloomf joins (~nbloomf@76.217.43.73)
2020-11-09 01:05:14 × acarrico quits (~acarrico@dhcp-68-142-39-249.greenmountainaccess.net) (Ping timeout: 256 seconds)
2020-11-09 01:05:15 × nbloomf quits (~nbloomf@76.217.43.73) (Client Quit)
2020-11-09 01:06:10 <Echosolace> Ok, interesting. So in my example, element 0 (first element in the list, -4.3) gets compared with -2.4, is true and gets grouped, then -4.3 gets compared again with -1.2 and also gets grouped. Is that correct?
2020-11-09 01:06:11 merijn joins (~merijn@83-160-49-249.ip.xs4all.nl)
2020-11-09 01:06:32 nbloomf joins (~nbloomf@2600:1700:ad14:3020:a17b:c481:d5f1:9100)
2020-11-09 01:09:40 <Echosolace> Sounds like it. Thanks for the help.
2020-11-09 01:09:43 × Echosolace quits (99ec1b94@p1276149-omed01.tokyo.ocn.ne.jp) (Remote host closed the connection)
2020-11-09 01:09:51 _ashbreeze_ joins (~mark@72-161-252-32.dyn.centurytel.net)
2020-11-09 01:12:10 xerox_ joins (~xerox@unaffiliated/xerox)
2020-11-09 01:12:48 todda7 joins (~torstein@athedsl-347721.home.otenet.gr)
2020-11-09 01:13:05 × tsaka__ quits (~torstein@athedsl-216011.home.otenet.gr) (Ping timeout: 240 seconds)
2020-11-09 01:16:53 × Rudd0 quits (~Rudd0@185.189.115.108) (Ping timeout: 260 seconds)
2020-11-09 01:17:23 acarrico joins (~acarrico@dhcp-68-142-39-249.greenmountainaccess.net)
2020-11-09 01:17:42 × mputz quits (~Thunderbi@dslb-084-058-211-084.084.058.pools.vodafone-ip.de) (Ping timeout: 256 seconds)
2020-11-09 01:17:45 × theelous3 quits (~theelous3@unaffiliated/theelous3) (Read error: Connection reset by peer)
2020-11-09 01:18:20 <bqv> looking for a datatype
2020-11-09 01:18:37 <bqv> must be short, blonde, and located in the penn state area
2020-11-09 01:18:52 <bqv> no, but seriously, i'm thinking of a write-only-list sort of thing
2020-11-09 01:19:33 <bqv> so far the closest i can think of is an IntMap where every entry is a Maybe and the delete operation is banned
2020-11-09 01:20:10 <bqv> my requirement is kinda that there's a unique index for every item added across the lifespan of this container
2020-11-09 01:21:33 × perrier-jouet quits (~perrier-j@modemcable012.251-130-66.mc.videotron.ca) (Quit: WeeChat 2.9)
2020-11-09 01:23:36 <bqv> the type i'm thinking of is i guess isomorphic to `IntMap (Maybe a)` and `[Maybe a]`, and I've gone for the former so far because i would need random access
2020-11-09 01:23:47 <bqv> just wondering if there's a better encoding
2020-11-09 01:23:57 × jmcarthur quits (~jmcarthur@2601:86:500:2a40:db56:5d66:5919:c95d) (Ping timeout: 244 seconds)
2020-11-09 01:24:39 xenon- joins (~bc8165ab@217.29.117.252)
2020-11-09 01:26:57 Lord_of_Life_ joins (~Lord@46.217.220.150)
2020-11-09 01:27:36 × Lord_of_Life quits (~Lord@unaffiliated/lord-of-life/x-0885362) (Ping timeout: 260 seconds)
2020-11-09 01:30:12 gproto023 joins (~gproto23@unaffiliated/gproto23)
2020-11-09 01:31:40 Tario joins (~Tario@201.192.165.173)
2020-11-09 01:32:35 inkbottle joins (~inkbottle@aaubervilliers-654-1-101-233.w86-212.abo.wanadoo.fr)
2020-11-09 01:33:11 × gproto23 quits (~gproto23@unaffiliated/gproto23) (Ping timeout: 258 seconds)
2020-11-09 01:33:48 × zebrag quits (~inkbottle@aaubervilliers-654-1-107-146.w86-212.abo.wanadoo.fr) (Ping timeout: 260 seconds)
2020-11-09 01:35:53 conal joins (~conal@209.58.139.27)
2020-11-09 01:38:07 <jle`> bqv: by write-only do you mean like append-only?
2020-11-09 01:38:24 <jle`> you can just use whatever data type you want and only export the operations that are allowed
2020-11-09 01:38:24 Jeanne-Kamikaze joins (~Jeanne-Ka@66.115.189.179)
2020-11-09 01:38:51 <jle`> pure datatypes are all persistent so you can't really truly have 'no undo', since you can just hold a reference to previous values
2020-11-09 01:40:05 × merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 258 seconds)
2020-11-09 01:40:51 × tmciver quits (~tmciver@172.101.40.226) (Ping timeout: 258 seconds)
2020-11-09 01:41:56 <bqv> jle`: yes, i do
2020-11-09 01:42:00 <bqv> and yeah i know
2020-11-09 01:42:09 <bqv> i was just wondering if this was an already packaged thing
2020-11-09 01:42:47 tmciver joins (~tmciver@cpe-172-101-40-226.maine.res.rr.com)
2020-11-09 01:43:23 jonatanb joins (~jonatanb@83.24.9.26.ipv4.supernova.orange.pl)
2020-11-09 01:46:11 × xerox_ quits (~xerox@unaffiliated/xerox) (Ping timeout: 256 seconds)
2020-11-09 01:48:08 × jonatanb quits (~jonatanb@83.24.9.26.ipv4.supernova.orange.pl) (Ping timeout: 260 seconds)
2020-11-09 01:49:14 sulu joins (~sulu@unaffiliated/sulu)
2020-11-09 01:51:32 × AceNovo quits (~chris@184.101.220.149) (Quit: Konversation terminated!)
2020-11-09 01:51:57 AceNovo joins (~chris@184.101.220.149)
2020-11-09 01:54:09 <xenon-> I need to create a relatively simple website for my personal use, and I want to give FRP a try. what library do you recommend?
2020-11-09 01:54:10 ski joins (~ski@remote11.chalmers.se)
2020-11-09 01:58:02 × Tops2 quits (~Tobias@dyndsl-095-033-091-035.ewe-ip-backbone.de) (Read error: Connection reset by peer)
2020-11-09 02:02:13 thir joins (~thir@p200300f27f0b7e00f4e9381c2bf90854.dip0.t-ipconnect.de)
2020-11-09 02:05:04 <jchia> xenon: Why do you need FRP for a website?
2020-11-09 02:06:32 <xenon-> I don't NEED it, I want to give it a try
2020-11-09 02:09:24 <bqv> jle`: what would you call, such a structure?
2020-11-09 02:12:02 × thir quits (~thir@p200300f27f0b7e00f4e9381c2bf90854.dip0.t-ipconnect.de) (Ping timeout: 260 seconds)
2020-11-09 02:15:26 yinfeng joins (~yinfeng@114.212.87.131)
2020-11-09 02:16:07 × conal quits (~conal@209.58.139.27) (Quit: Computer has gone to sleep.)
2020-11-09 02:16:49 × Jeanne-Kamikaze quits (~Jeanne-Ka@66.115.189.179) (Quit: Leaving)
2020-11-09 02:17:09 × nbloomf quits (~nbloomf@2600:1700:ad14:3020:a17b:c481:d5f1:9100) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-11-09 02:21:23 tsaka__ joins (~torstein@ppp-2-84-16-76.home.otenet.gr)
2020-11-09 02:21:53 × todda7 quits (~torstein@athedsl-347721.home.otenet.gr) (Ping timeout: 256 seconds)
2020-11-09 02:27:45 × Tario quits (~Tario@201.192.165.173) (Ping timeout: 240 seconds)
2020-11-09 02:28:46 Tario joins (~Tario@201.192.165.173)
2020-11-09 02:29:34 toorevitimirp joins (~tooreviti@117.182.180.38)
2020-11-09 02:34:02 perrier-jouet joins (~perrier-j@modemcable012.251-130-66.mc.videotron.ca)
2020-11-09 02:35:53 todda7 joins (~torstein@ppp-2-84-27-192.home.otenet.gr)
2020-11-09 02:36:04 × tsaka__ quits (~torstein@ppp-2-84-16-76.home.otenet.gr) (Ping timeout: 256 seconds)
2020-11-09 02:37:28 xerox_ joins (~xerox@unaffiliated/xerox)
2020-11-09 02:38:10 × shatriff quits (~vitaliish@176.52.219.10) (Remote host closed the connection)
2020-11-09 02:40:19 <Axman6> xenon-: obilisk seems to the the simplest way to start with FRP using Reflex I believe
2020-11-09 02:44:37 leungbk joins (~user@2605:e000:1315:706:1ea1:e5bb:dc92:96fe)
2020-11-09 02:49:10 conal joins (~conal@209.58.139.27)
2020-11-09 02:49:40 × mmohammadi9812 quits (~mmohammad@5.238.175.25) (Ping timeout: 272 seconds)
2020-11-09 02:50:07 Stanley00 joins (~stanley00@unaffiliated/stanley00)
2020-11-09 02:51:02 × xff0x quits (~fox@2001:1a81:52da:100:72bb:28a0:cf70:9b87) (Ping timeout: 264 seconds)
2020-11-09 02:51:55 nbloomf joins (~nbloomf@2600:1700:ad14:3020:a17b:c481:d5f1:9100)
2020-11-09 02:51:56 drbean joins (~drbean@TC210-63-209-143.static.apol.com.tw)
2020-11-09 02:52:03 × lemmih quits (~lemmih@2406:3003:2072:44:2c90:c5a8:23d6:f0a8) (Remote host closed the connection)

All times are in UTC.