I once attempted to implement the Senate counting algorithm (mostly so I could force myself to truly understand it).
I can say with great confidence that it is hard to implement correctly, and it would take more than a single external audit to give me confidence that the AEC's implementation is flawless.