How can i make this code faster?

How can i make this code faster