Ecclesiastes 3:15-18 New American Standard Bible (NASB)

15. That which is has been already and that which will be has already been, for God seeks what has passed by.

16. Furthermore, I have seen under the sun that in the place of justice there is wickedness and in the place of righteousness there is wickedness.

17. I said to myself, "God will judge both the righteous man and the wicked man," for a time for every matter and for every deed is there.

18. I said to myself concerning the sons of men, "God has surely tested them in order for them to see that they are but beasts."

Ecclesiastes 3