Having trouble using code I downloaded

I'm just asking why its producing an error and how i can fix it.