Logs: freenode/#haskell
| 2021-04-20 12:07:43 | <kuribas> | Don't try and fit in every abstraction, just write code that solves the problem, then rewrite it. |
| 2021-04-20 12:07:58 | <merijn> | That doesn't apply to homework :p |
| 2021-04-20 12:08:33 | <kuribas> | Depends on the task? |
| 2021-04-20 12:11:26 | → | nineonine joins (~nineonine@50.216.62.2) |
| 2021-04-20 12:12:03 | → | nineonin_ joins (~nineonine@50.216.62.2) |
| 2021-04-20 12:13:29 | → | zariuq joins (~zar@fw1.ciirc.cvut.cz) |
| 2021-04-20 12:13:45 | <dibblego> | alexm_: by now, we've told the class at least 50 times how lift2 works, and its intuition |
| 2021-04-20 12:15:41 | × | nineonine quits (~nineonine@50.216.62.2) (Ping timeout: 240 seconds) |
| 2021-04-20 12:16:34 | <merijn> | dibblego: So what you're saying is that about 50% remembers at this point? ;) |
| 2021-04-20 12:17:28 | <alexm_> | dibblego: yeah, it takes some time to sink in I guess |
| 2021-04-20 12:18:02 | <alexm_> | and actually implementing it helps a lot |
| 2021-04-20 12:18:15 | <maerwald> | :t lift2 |
| 2021-04-20 12:18:17 | <lambdabot> | error: |
| 2021-04-20 12:18:17 | <lambdabot> | • Variable not in scope: lift2 |
| 2021-04-20 12:18:17 | <lambdabot> | • Perhaps you meant one of these: |
| 2021-04-20 12:18:32 | <dibblego> | not even 10% usually |
| 2021-04-20 12:19:18 | <maerwald> | never head of lift2 |
| 2021-04-20 12:20:06 | <alexm_> | it's liftA2 actually |
| 2021-04-20 12:20:12 | × | star_cloud quits (~star_clou@ec2-34-220-44-120.us-west-2.compute.amazonaws.com) (Ping timeout: 240 seconds) |
| 2021-04-20 12:20:27 | <merijn> | dibblego: ;) |
| 2021-04-20 12:20:38 | <alexm_> | it's just the function from the course named lift2 |
| 2021-04-20 12:23:23 | × | Tops2 quits (~Tobias@dyndsl-095-033-023-254.ewe-ip-backbone.de) (Quit: Leaving.) |
| 2021-04-20 12:23:36 | → | Guillaum joins (guiboumatr@gateway/shell/matrix.org/x-jujgaxapscnlvbmt) |
| 2021-04-20 12:24:29 | → | nicholasbulka joins (~nicholasb@2601:900:4301:da0:c46c:29eb:6d58:88ee) |
| 2021-04-20 12:24:40 | → | Tops2 joins (~Tobias@dyndsl-095-033-023-254.ewe-ip-backbone.de) |
| 2021-04-20 12:28:57 | × | nicholasbulka quits (~nicholasb@2601:900:4301:da0:c46c:29eb:6d58:88ee) (Ping timeout: 250 seconds) |
| 2021-04-20 12:29:36 | → | basenode joins (~user@gateway/tor-sasl/basenode) |
| 2021-04-20 12:29:42 | ← | basenode parts (~user@gateway/tor-sasl/basenode) () |
| 2021-04-20 12:31:49 | × | usr25 quits (~usr25@unaffiliated/usr25) (Quit: Leaving) |
| 2021-04-20 12:32:23 | × | geowiesnot quits (~user@i15-les02-ix2-87-89-181-157.sfr.lns.abo.bbox.fr) (Ping timeout: 246 seconds) |
| 2021-04-20 12:33:05 | → | basenode joins (~user@gateway/tor-sasl/basenode) |
| 2021-04-20 12:33:22 | → | star_cloud joins (~star_clou@ec2-34-220-44-120.us-west-2.compute.amazonaws.com) |
| 2021-04-20 12:33:43 | → | nineonine joins (~nineonine@2604:3d08:7785:9600:e0d9:4197:14e4:81a) |
| 2021-04-20 12:35:02 | → | alx741 joins (~alx741@181.196.68.199) |
| 2021-04-20 12:35:27 | × | kritzefitz quits (~kritzefit@2003:5b:203b:200::10:49) (Ping timeout: 250 seconds) |
| 2021-04-20 12:35:58 | → | xourt joins (d4c620ea@212-198-32-234.rev.numericable.fr) |
| 2021-04-20 12:37:37 | × | nineonin_ quits (~nineonine@50.216.62.2) (Ping timeout: 252 seconds) |
| 2021-04-20 12:37:58 | → | nineonin_ joins (~nineonine@50.216.62.2) |
| 2021-04-20 12:38:01 | <basenode> | anyone here that i was talking to yesterday? |
| 2021-04-20 12:38:11 | → | kritzefitz joins (~kritzefit@2003:5b:203b:200::10:49) |
| 2021-04-20 12:38:43 | × | ubert1 quits (~Thunderbi@62-47-7-125.adsl.highway.telekom.at) (Ping timeout: 252 seconds) |
| 2021-04-20 12:39:55 | → | hypercube joins (hypercube@gateway/vpn/protonvpn/hypercube) |
| 2021-04-20 12:40:13 | × | nineonine quits (~nineonine@2604:3d08:7785:9600:e0d9:4197:14e4:81a) (Ping timeout: 250 seconds) |
| 2021-04-20 12:40:24 | → | ddellaco_ joins (~ddellacos@ool-44c73afa.dyn.optonline.net) |
| 2021-04-20 12:40:56 | → | _bin_ joins (~bin@2600:1700:10a1:38d0:219a:3dd:429e:7909) |
| 2021-04-20 12:41:49 | × | _bin quits (~bin@2600:1700:10a1:38d0:8028:8b86:7e11:f5b5) (Ping timeout: 258 seconds) |
| 2021-04-20 12:42:26 | × | todda7 quits (~torstein@athedsl-4519432.home.otenet.gr) (Ping timeout: 240 seconds) |
| 2021-04-20 12:43:55 | ski | looks at basenode |
| 2021-04-20 12:44:04 | <basenode> | ski: oh hey dude! |
| 2021-04-20 12:44:07 | × | xourt quits (d4c620ea@212-198-32-234.rev.numericable.fr) (Quit: Connection closed) |
| 2021-04-20 12:44:32 | × | ddellaco_ quits (~ddellacos@ool-44c73afa.dyn.optonline.net) (Ping timeout: 240 seconds) |
| 2021-04-20 12:45:42 | → | ddellaco_ joins (~ddellacos@ool-44c73afa.dyn.optonline.net) |
| 2021-04-20 12:45:46 | <basenode> | just thought i would share the implementation for the algo we discussed yesterday, i didn't come up with it but it thought it was so elegant i had to share it |
| 2021-04-20 12:46:28 | <basenode> | ski: -> https://dpaste.com/7VMXVC9XX |
| 2021-04-20 12:47:14 | → | Sorna joins (~Sornaensi@077213200034.dynamic.telenor.dk) |
| 2021-04-20 12:47:47 | <basenode> | all relatively self-explanatory, except Enum.group_by, which splits an enumerable into groups based on a function you pass it |
| 2021-04-20 12:48:07 | × | nyd quits (~nyd@unaffiliated/elysian) (Quit: nyd) |
| 2021-04-20 12:50:38 | <ski> | what happens if you have more than one root ? |
| 2021-04-20 12:51:23 | × | Sornaensis quits (~Sornaensi@79.142.232.102.static.router4.bolignet.dk) (Ping timeout: 265 seconds) |
| 2021-04-20 12:51:52 | <basenode> | it still works :) |
| 2021-04-20 12:52:08 | <ski> | do you get the tree for the last root ? |
| 2021-04-20 12:52:25 | <basenode> | yeah also |
| 2021-04-20 12:53:59 | <ski> | (also what ?) |
| 2021-04-20 12:55:23 | × | ericsagnes quits (~ericsagne@2405:6580:0:5100:e608:c88b:5ed1:a466) (Ping timeout: 250 seconds) |
| 2021-04-20 12:55:41 | × | Gurkenglas quits (~Gurkengla@unaffiliated/gurkenglas) (Ping timeout: 240 seconds) |
| 2021-04-20 12:55:48 | <basenode> | ski: not sure i understood the question entirely, you were asking if i get the tree for the last root element? |
| 2021-04-20 12:56:25 | <basenode> | "yeah also" as in yes, i also get the tree for the last root element |
| 2021-04-20 12:56:26 | <ski> | yes, in case you have more than one `id' whose `parent_id' is `nil' |
| 2021-04-20 12:56:38 | × | plutoniix quits (~q@ppp-124-122-197-70.revip2.asianet.co.th) (Quit: Leaving) |
| 2021-04-20 12:56:52 | × | hypercube quits (hypercube@gateway/vpn/protonvpn/hypercube) (Ping timeout: 240 seconds) |
| 2021-04-20 12:56:59 | <basenode> | yeah, all trees for each root element are returned |
| 2021-04-20 12:58:07 | → | lambdaman joins (~lambdaman@s66-183-152-156.bc.hsia.telus.net) |
| 2021-04-20 12:58:12 | <ski> | hm, okay |
| 2021-04-20 12:58:37 | <ski> | i'm not completely following the details of the code, but from what i understand, it looks nice |
| 2021-04-20 12:58:50 | <ski> | (and you're doing a top-down, rather than a bottom-up solution) |
| 2021-04-20 12:59:21 | × | lambdaman quits (~lambdaman@s66-183-152-156.bc.hsia.telus.net) (Remote host closed the connection) |
| 2021-04-20 13:00:10 | → | lambdaman joins (~lambdaman@s66-183-152-156.bc.hsia.telus.net) |
| 2021-04-20 13:00:18 | → | nicholasbulka joins (~nicholasb@2601:900:4301:da0:c46c:29eb:6d58:88ee) |
| 2021-04-20 13:02:21 | × | finn_elija quits (~finn_elij@gateway/tor-sasl/finnelija/x-67402716) (Ping timeout: 240 seconds) |
| 2021-04-20 13:03:03 | → | horatiohb joins (~horatiohb@104.131.33.15) |
| 2021-04-20 13:04:26 | → | finn_elija joins (~finn_elij@gateway/tor-sasl/finnelija/x-67402716) |
| 2021-04-20 13:05:09 | <basenode> | ski: this implementation is from the creator of elixir (jose valim), but yeah it's a beautiful piece of code, all of my attempts were far more complex and didn't work lol |
| 2021-04-20 13:05:23 | <basenode> | thought you might appreciate it though ;) |
| 2021-04-20 13:06:14 | <ski> | ah, Elixir |
| 2021-04-20 13:06:35 | <ski> | it's quite simple and elegant, yea |
| 2021-04-20 13:06:55 | <ski> | (i wonder what the difference between `def' and `defp' is) |
| 2021-04-20 13:07:28 | <ski> | (hm, the paste even said it, i just didn't notice) |
| 2021-04-20 13:07:30 | → | hyperisco joins (~hyperisco@d192-186-117-226.static.comm.cgocable.net) |
| 2021-04-20 13:07:53 | → | ericsagnes joins (~ericsagne@2405:6580:0:5100:7192:af15:79b1:35f5) |
| 2021-04-20 13:09:25 | → | philderbeast joins (~textual@bras-base-vldvpq5901w-grc-06-184-144-244-252.dsl.bell.ca) |
| 2021-04-20 13:10:04 | × | Pickchea quits (~private@unaffiliated/pickchea) (Ping timeout: 252 seconds) |
| 2021-04-20 13:10:11 | → | carlomagno joins (~cararell@148.87.23.7) |
| 2021-04-20 13:11:52 | → | son0p joins (~ff@181.136.122.143) |
| 2021-04-20 13:12:00 | <lechner> | Hi, is there a way to round timestamps from getCurrentTime to microseconds (or even seconds) please? Thanks! |
| 2021-04-20 13:16:15 | <joel135> | :t getCurrentTime |
| 2021-04-20 13:16:16 | <lambdabot> | error: Variable not in scope: getCurrentTime |
| 2021-04-20 13:16:41 | <joel135> | IO UTCTime |
| 2021-04-20 13:16:55 | <ski> | @hoogle getCurrentTime |
| 2021-04-20 13:16:55 | <lambdabot> | Data.Time.Clock getCurrentTime :: IO UTCTime |
| 2021-04-20 13:16:55 | <lambdabot> | Data.Time.Clock.POSIX getCurrentTime :: IO UTCTime |
All times are in UTC.