smart aleck, a

smart alec(k)

One who makes jokes and uses sarcasm in an attempt to seem witty, but instead is deemed annoying. I'd had enough of that smart aleck's wisecracks, so I left the party early. Don't be such a smart alec, Sally.
See also: smart
Farlex Dictionary of Idioms. © 2015 Farlex, Inc, all rights reserved.

smart aleck

An impudent or obnoxiously self-assertive individual, a wise guy, as in New teachers often have a hard time coping with the smart alecks in their classes. This expression, dating from the mid-1800s, probably alluded to a person of this description who was named Alec or Alexander, but his identity has been lost.
See also: aleck, smart
The American Heritage® Dictionary of Idioms by Christine Ammer. Copyright © 2003, 1997 by The Christine Ammer 1992 Trust. Published by Houghton Mifflin Harcourt Publishing Company. All rights reserved.

smart aleck, a

A cocky individual who thinks he or she knows everything and is not shy about saying so. The origin of this term, an American colloquialism from the 1860s, has been lost; no one knows who that first Aleck (or Alexander) was. The adjective smart in the sense of “impudent” is much older (fifteenth century) but has died out except in this expression. Budd Schulberg used it in What Makes Sammy Run? (1941): “He’s a smart aleck. I can see already he thinks he knows more than I do.”
See also: smart
The Dictionary of Clichés by Christine Ammer Copyright © 2013 by Christine Ammer
See also: