Throw the book at ’em!

Two teens attacked an elderly man who tried to break up their apparent play fight in front of a Queens library, according to sources and disturbing footage released by the NYPD.

The vicious assault, which happened just after 11 a.m. Oct. 8, left the 79-year-old victim with a broken femur and ribs, according to police, who released the footage Monday.

The two teenage boys appeared to be play-fighting in front of the Cambria Heights Public Library on Linden Avenue when they were approached by the man, who tried to break up the fisticuffs, a source in the police department said.

The boys turned on the man and began chasing him down the sidewalk, according to the video.

One of the kids pushed the man to the ground while the other barraged him with punches to the face and chest, according to the police and video footage.

The attackers fled, and the victim was taken to Long Island Jewish Valley Stream Hospital, cops said.