This is a very simple melody that clearly outlines the major 7 sound (with a passing natural 11). First learn to sing the melody in one key to get familiar with the sound and help internalize the phrase. Singing is the fastest and most effective way to train your ear. Recognize that we tend to sing a melody much slower than we play it (if we are singing in tune), this should give you some insight as to how fast you should be practicing an idea; play it as slowly as you sing it.
Once the phrase is easy to sing in tune, begin playing it through the keys on your instrument. Remember to stay relaxed, listen and feel the underlying pulse while using a metronome.
For variation, try playing the melody in triplets or displacing the melody by and eighth note. Also, flatting the 7th and/or 3rd can transform the melody from major to dominant or minor.