So he said ‘I’m going to chop off the bottom of one of your trouser legs and put it in a library.’ I thought ‘That’s a turn-up for the books.’
Meaning of the quote
The quote is a joke playing on the phrase "turn-up for the books." The comedian is saying that someone planned to cut off the bottom of someone's pants and put it in a library, which is a surprising and unexpected event, like a "turn-up for the books" (a surprising or unusual occurrence). The humor comes from the absurdity of the proposed action and the play on words with the common expression.

About Tommy Cooper
Tommy Cooper was a larger-than-life Welsh prop comedian and magician who became an international star on television in the 1970s. Despite his success, his career and health declined due to heavy smoking and drinking, leading to his sudden death on live TV at the age of 63.
More quotes from Tommy Cooper
Police arrested two kids yesterday, one was drinking battery acid, the other was eating fireworks. They charged one and let the other one off.
British prop comedian and magician (1921-1984)
A blind bloke walks into a shop with a guide dog. He picks the Dog up and starts swinging it around his head. Alarmed, a shop assistant calls out: ‘Can I help, sir?’ ‘No thanks,’ says the blind bloke. ‘Just looking.’
British prop comedian and magician (1921-1984)
Well, my wife and I were married in a toilet – it was a marriage of convenience!
British prop comedian and magician (1921-1984)
I went window shopping today! I bought four windows.
British prop comedian and magician (1921-1984)
So I rang up a local building firm, I said ‘I want a skip outside my house.’ He said ‘I’m not stopping you.’
British prop comedian and magician (1921-1984)
So he said ‘I’m going to chop off the bottom of one of your trouser legs and put it in a library.’ I thought ‘That’s a turn-up for the books.’
British prop comedian and magician (1921-1984)
I went into a French restaraunt and asked the waiter, ‘Have you got frog’s legs?’ He said, ‘Yes,’ so I said, ‘Well hop into the kitchen and get me a cheese sandwich.’
British prop comedian and magician (1921-1984)
You know, somebody actually complimented me on my driving today. They left a little note on the windscreen, it said ‘Parking Fine.’
British prop comedian and magician (1921-1984)
I used to be indecisive but now I am not quite sure.
British prop comedian and magician (1921-1984)
A woman tells her doctor, ‘I’ve got a bad back.’ The doctor says, ‘It’s old age.’ The woman says, ‘I want a second opinion.’ The doctor says: ‘Okay – you’re ugly as well.’
British prop comedian and magician (1921-1984)
So I was getting into my car, and this bloke says to me ‘Can you give me a lift?’ I said ‘Sure, you look great, the world’s your oyster, go for it.’
British prop comedian and magician (1921-1984)
Last night I dreamt I ate a ten pound marshmallow. When I woke up the pillow was gone.
British prop comedian and magician (1921-1984)