Missatge de Raul Miller <rauldmil...@gmail.com> del dia dc., 14 de des. 2022 a les 18:33:
> On Wed, Dec 14, 2022 at 2:26 AM Jaume <greenni...@gmail.com> wrote: > > Because somewhere in there something broke and on the phone I have the > > wrong answer for part 1. > > Yes... generally it's easier to debug if you have a much smaller > implementation. > The first days I tried, now I have less time and the problems are harder. > It's also a *lot* easier if you write your code so that you can test > against the sample data posted in the puzzle description. > Yep, doing that always. I have dXXtN.input for the N test inputs for each day (usually one) and dayXX.input for the real input. > Also... for what it's worth, here's an example of how you might parse > the data set for that puzzle: > [...] > Thanks, I will look at that. I love that an explanation accompanies it. I have to say that parsing the input sometimes is the hardest part for me (with J). On day 11 I parsed it manually and created 7 sets of elements for the real input, plus the 4 for the test. It took less time than trying to create the parser. On day 7 both the input and the processing were too hard for me (in J) so I had to resort to C#. I still can't think J enough and lack some knowledge. Even with that this year I'm quite happy with my results so far. Last time I tried J was back in '19, and tried to do it with my mobile phone while commuting. Too hard, too many things to write. And because I wasn't able to parse the first intcode day I didn't continue after the next one appeared. I'm improving on several fronts. Learning more J day by day, sometimes in a surprising fashion, like the day after I read about &: and thought "this is probably a fringe mathematical construct, I will not use it" I used it for counting the threes. Learning more how jqt works, like on day 11 that I learned about ctrl+E. On day 13 I learned to debug (not as well as I'd like) and changed my work style, so instead of working on jqt and copying from time to time everything on a log file I write on the file and copy it and F8 on jqt. I'd use the J extension for VScode, but it's not finding ijconsole, probably because it's a SteamDeck, which has lots of things locked down. It doesn't find dotnet either (and I have both). And because I have to share the solutions with the people at work some days (like today) I'm going through the previous days and creating a more palatable presentation. It's a fun experience and the helpfulness from all the people here brings even more joy. Thanks again everyone. Now back to cleaning past days' submissions. ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm