What are the pentatonic scales?
Penta means five. Take a major scale and leave out the two notes that make its half steps, the 4th and the 7th, and five notes remain: 1 2 3 5 6. In C that is C D E G A, the major pentatonic scale. With no half steps inside it, no two of its notes grind against each other.
The minor pentatonic is the minor scale without its 2nd and 6th: 1 ♭3 4 5 ♭7. In A that is A C D E G, exactly the five keys of C major pentatonic counted from the sixth note, the same way A minor shares C major’s notes. Learn one set of five and you know both.
What is the blues scale?
Add one note to the minor pentatonic, the flat 5th, and you have the blues scale: 1 ♭3 4 ♭5 5 ♭7. In C that is C E♭ F G♭ G B♭. The G♭ is the added blue note. It sits a half step from the 5th beside it, and players slide through it or lean on it for a moment rather than rest there.
Why do they work for improvising?
Two reasons. Fewer notes means fewer wrong ones, because these scales leave out the notes most likely to clash with a chord. And in a twelve-bar blues, the minor pentatonic and blues scale built on the key’s tonic work over all three chords even as the chords change; the ♭3 rubbing against a major chord is the sound of the style, not a mistake. Over a major-key pop loop such as I–V–vi–IV, the key’s major pentatonic plays the same safe role.
The easiest place to hear it is the black keys. Take G♭ as home and they are G♭ major pentatonic (G♭ A♭ B♭ D♭ E♭); take E♭ as home and they are E♭ minor pentatonic (E♭ G♭ A♭ B♭ D♭). Improvise on black keys alone and almost any choice sounds like music.