Advent of Code 2023

In contrast to day 2, where I found parsing to be the most difficult part, on day 4, formatted input worked like a charm (especially if you fix the dimensions in advance).

For part 1, I came with this two-liner:

nwin = [(count([(any(tw(j,i) == tm(:,i)),j=1,nw)]), i = 1, nc)]
print *, "TOTAL POINTS = ", sum(pack(2**(nwin-1),mask=nwin > 0))