Arduino MIDI interface - Serial was not declared in this scope
What kind of Arduino are you using? Only the Arduino Mega and Due can access Serial3 (reference link). Try replacing it with just plain-old Serial if you're not using one of these.

Also, your for loop is missing the condition argument (that's what the third line in your compile error list is whining about).