Elementary number theory: primes congruences and secrets : a computational approach Prime numbers The ring of integers modulo n Public key cryptography Quadratic reciprocity Continued fractions Elliptic curves This is a textbook about classical elementary number theory and elliptic curves. The first part discusses elementary topics such as primes factorization continued fractions and quadratic forms in the context of cryptography computation and deep open research problems. The second part is about elliptic curves their applications to algorithmic problems and their connections with problems in number theory such as Fermatās Last Theorem the Congruent Number Problem and the Conjecture of Birch and Swinnerton Dyer. The intended audience of this book is an undergraduate with some familiarity with basic abstract algebra e.g. rings fields and finite abelian groups