PaulS:
delay(5); //delay to allow buffer to fillIs STILL a bull$#!+ bandaid solution that sometimes work for some baud rates. If you don't want to learn to read serial data properly, you will continue to have (intermittent) problems. Bite the bullet; learn to send and receive serial data properly.
The Nick Gammon blog, if learned and understood teaches that very well.
I just hope that the OP gains proficiency at C/Arduino quickly.
One rule I learned right at the start: Everything Counts. Every last letter or symbol, anything out of place WILL cause the code to either stop or do what you did not want. Double and triple check on the slightest doubt or even lack of strong certainty.
Back in my day we had no internet but we could get books and load them with bookmarks. Now with the net I keep browser tabs to whatever references I need, the Arduino site has many and web pages make the rest. Even after years of coding I still look up commands because I hate wasting time doing to fix what I didn't do right.
DON'T be guessing. Every time you check first, you reinforce the correct knowledge where if you don't then you do not learn but your knowing fades a little in doubt and shadow-poking.