From GarageBand’s Track menu, select New Track, then click the green Software Instrument option on the left. Click the Create button to make a new track.
From the instrument list in the Track Info pane, select the right sound for your part. You can choose a drum kit, or any pitched instrument such as a piano.
You need to start with a blank MIDI region. Create by holding down Cmd and clicking the Arrange window at the point where you want the region to go.
The new region will default to a length of just one bar. If you need it to be longer, position the cursor over the right-hand edge and drag it out to the correct length.
Double-click your new region or click the scissors button in the lower left corner to open the Track Edit window, then hit the Score tab to enter Notation View.
From the Control menu, select the Snap to Grid option to make sure that any new notes are placed in line with the quantise grid.
There are three clef display options. These are selected by holding down the mouse over the current symbol and choosing either treble, bass or piano-style display.
Hold the mouse button over the Insert menu and a grid of different note length symbols will appear. Select the correct one to choose the length of your first note.
Hold down the Cmd key and click on the staff at the position you want the first note to appear. A grey ghost note illustrates where the note will be placed.
Click Image to Enlarge: