After transmigrating to the Tang Dynasty, Mo Bai becomes the scapegoat in the imperial examination hall. While everyone else composes poetry, he pulls out counting rods and works through calculations on the spot. The Censor-in-Chief sneers, “This man is insane. Drag him out and execute him!” But when the Turkic army marches on the city, Mo Bai uses the Pythagorean theorem to measure the distance and a geometric sequence to arrange the troops, then shoots an arrow straight through the enemy commander’s banner. The emperor asks in astonishment, “What sorcery is this?” Mo Bai coolly tosses out a system of equations. “Your Majesty, shall we calculate the imperial treasury’s accounts?”