Take a note (this will be your tonic), then move up the notes by the following steps - tone, tone, semitone, tone, tone, tone, semitone. That is 2 tones and a semitone, then 3 tones and a semitone. Repeat the pattern up the piano.
Work out some major scales. Pick a random note as a tonic, then work upwards.
tone, tone,
semitone,
tone, tone, tone,
semitone.
Use one of the major scales you have worked out to play a simple melody such as Twinkle Twinkle.
Here is the start, using the scales degrees 1 - 7:
1, 1, 5, 5, 6, 6, 5, 4, 4, 3, 3, 2, 2, 1
See if you can work out the rest for yourself. Then try it using other major scales.