Who lives in a Pineapple in the Algorithms Library for C? SpongeBob BinaryTreePants!

merari42@lemmy.world to Programmer Humor@programming.dev – 630 points –
20

You are viewing a single comment

It definitely wouldn't be the left image. With legs like those, you could never pull the pants up past the first (or I guess technically last) level of branching. It would either be the big pants or a large number of seperate, smaller pants on each of the lowest branches.

They could use pull-away pants that button up the back maybe

Have you ever seen a binary tree grow? Maybe they put the pants on each level while it is the lowest one before the next level grows

If the pants are stretchy they could fit one of the lowest (already pantsd) branches in each leg of the jeans, and easily pull it up. You need bigger and stretchier pants as you go up the tree, though.

The max size of required pants stretch will be the standard size for the right picture, since each leg already wraps half of the tree. That confirms viability at least, so now I think it's down to comfort, and does the stretch retract in a restful position, or does stay all loose and cumbersome?

are the legs not allowed to be detached even for a moment for maintenance?