Speaking as a total ignorant from a coding perspective. But I guess that wouldn’t be the hard part, considering that most of Duolinguo is just boxes and text inputs. How difficult it is to create a database of competent linguists with an efficient training who can progressively enhance your understanding of languages?
I think this question is a XY problem. You want to learn a language and not build an app for learning languages. To learn a language you just need motivation and resolve to stick with it for long periods of time. Just grab a text book, some video courses and flashcards.