Can digital pins get 9v

I am mixing Lego and arduino. Lego has an output of 9v. Is it okay for 9v to go into the arduino's digital pins?

No (you can check the datasheet for the limits!). Add a series resistor (relying on the clamping diodes - at least 4k7, 10-22k is better) or a voltage divider.

zachfrish: I am mixing Lego and arduino. Lego has an output of 9v. Is it okay for 9v to go into the arduino's digital pins?

Never, not even for a microsecond, instant destruction.

Thank you