We show that the characteristic polynomial and the Lefschetz zeta function are manifestations of the trace map from the K-theory of endomorphisms to topological restriction homology (TR). Along the way we generalize Lindenstrauss and McCarthy's map from K-theory of endomorphisms to topological restriction homology, defining it for any Waldhausen category with a compatible enrichment in orthogonal spectra. In particular, this extends their construction from rings to ring spectra. We also give a revisionist treatment of the original Dennis trace map from K-theory to topological Hochschild homology (THH) and explain its connection to traces in bicategories with shadow (also known as trace theories). CONTENTS 1. Introduction 1 2. Preliminaries: duality, bicategories, and spectra 6 3. Spectral categories and spectral Waldhausen categories 12 4. Bimodules over spectral categories and their traces 15 5. The additivity theorem for THH, revisited 19 6. The Dennis trace 24 7. The equivariant Dennis trace 30 8. The trace to topological restriction homology 36 9. Characteristic polynomials, zeta functions, and the Reidemeister trace 41 Appendix A. Model categories of restriction systems 51 References 53