no banana to Lemmy Shitpost@lemmy.world • 1 year agoLmklemmy.worldimagemessage-square71fedilinkarrow-up1844arrow-down10
arrow-up1844arrow-down1imageLmklemmy.worldno banana to Lemmy Shitpost@lemmy.world • 1 year agomessage-square71fedilink
minus-squareAnanacelinkfedilink14•1 year agoIf you build a linked list in C, and put the pointer to the next entry as the first element in your struct, then you only need a single variable (and two comparisons) to do sorted insertion into the list.
If you build a linked list in C, and put the pointer to the next entry as the first element in your struct, then you only need a single variable (and two comparisons) to do sorted insertion into the list.