Rewrote with different implementation