Nothing to do with your code.
you need to study your wiring a bit more.
are you connecting the 5V supply to "Vin" or "5V" on your arduinos?
Nothing to do with your code.
you need to study your wiring a bit more.
are you connecting the 5V supply to "Vin" or "5V" on your arduinos?