No one is sure how it came into being, but it did appear in classic text.
First let's talk about
得 simply means "to get".
了 could have several meanings, notably:
- To learn, to know, as in
- To finish, to give up, as in
Both these two meanings are seen in classic usage of
宋 《朱子语类》卷八：“大凡学者，无有径截一路，可以教他了得。”—— For anyone who is pursuing knowledge, there is no shortcut, that could teach him to learn.
宋 苏轼 《与王定国书》：“某自謫居以来，可了得易传九卷，论语五卷。”—— I've finished 9 chapters of 易传 and 5 chapters of 论语 since I've been demoted.
But we also have
了得 that means "extraordinary, remarkable, capable" in classical text:
唐 李山甫 《游侠儿》诗：“ 荆轲只为闲言语，不与燕丹了得人。”—— It's because of fear of rumors that 荆轲 did what he did, not because 燕丹 is a remarkable personality.
了得 is quite an ancient word. I couldn't find the origin of the last meaning, but from the first two meanings, you have someone who learns, and you have someone who gets things done, isn't that remarkable?
了得 also exists in
这还了得 as a negative remark on something bad, like saying "How is this for gratitude", which means no gratitude at all:
《红楼梦》第五十回：“这还了得！他（画图）竟比盖这园子还费工夫了。”——How unbelievable! It takes more time painting the garden than actually building it.
 Song dynasty, 960 - 1279 A.D.
 Tang dynasty, 618 - 907 A.D.
 He tried to assassinate 秦始皇, the first emperor of Qin, but failed and was killed.
了不得 is kind of a negative form of
了得. It is also quite old. Here are also some usage examples:
As a negative form,
了不得 was mostly used for bad things. But as time goes by, the boundary seems to have been blurred a bit.
了不得 seems to mean
了不起 in some cases.
References from website 汉典:
I'll refrain from the talking about these two because it's going to get muddy: