Experimented with head/tail implementation

Finding ideal seams is pretty slow (2.5 seconds), but is more or less a
one-time pass.