Chart of Major Scales
The chart below lists the most common major keys, the notes contained in them, along with the scale degree names and numbers. Some major scales are enharmonic, that is, they sound the same but are spelled differently. For exmaple, the C# and Db major scales sound the same but one uses sharps while the other uses flats. You may wonder why this is done, and the answer mainly has to do with the context in which they are found. If a composer writes a composition that uses mostly flats, it is easier to use Db major, while in the context of mostly sharps, C# major makes more sense.
It's worth noting that some possible keys are not listed here because they use double-sharps or double-flats. For example, the G# major scale has the following notes: G# A# B# C# D# E# FX G#, where "X" means a double-sharp. Keys like this do not usually occur in music because key signatures do not contain double-sharps and double-flats. But they happen occasionally, though such scales are more theoretical than practical.
All major scales, whether they use naturals (all white keys), flats, or sharps, are built using the same set of rules:
1. Spell in strict alphabetical order.
2. Use the major scale formula which consists of the following intervals in order: W W H W W W W H (where "W" means a whole step and "H" a half-step.
Following these two steps faithfully will determine the correct sharps or flats to use. By the way, with major scales, sharps and flats are not mixed in a given scale; it is either sharps or flats, not both.
For example, the C major scale uses the following alphabetical letters and corresponds to the major scale formula:
C W D W E H F W G W A W B H C
This is perhaps easiest to see on a guitar string or piano keyboard: