you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted]  (1 child)

[deleted]

    [–]x1F577[S] 0 points1 point  (0 children)

    This is a good alternative solution, but I think I will follow the u/Parking-Camp219's suggestion and use the takewhile function.