Throughout history, technological revolutions have been driven by the invention of machines. But today, the power of the technology transforming our world lies in an intangible and impenetrable cosmos of software: algorithmic code. In a world increasingly governed by technologies that so few can comprehend, who-or what-controls the future? Devil in the Stack follows Andrew Smith on his immersive trip into the world of coding, passing through the stories of logic, machine-learning and early computing, from Ada Lovelace to Alan Turing, and up to the present moment, behind the scenes into the lives and minds of the pioneers of the 21st century: those who write code. Smith embarks on a quest to understand this sect in what he believes to be the only way possible: by learning to code himself. Expansive and effervescent, Devil in the Stack delivers a portrait of code as both a vivid culture and an impending threat. By turns revelatory, unsettling and joyously funny, this is an essential book for our times, of vital interest to anyone hoping to participate in the future-defining technological debates to come.