King Solomon and Galileo agreed on science and religion to be two different things.
They both believed religion shouldn’t take the place of science and science shouldn’t take the place of religion.
King Solomon believed God hid secrets in this world and our purpose is to look for those secrets and that is the reason for science.
It is the glory of God to conceal things, but the glory of kings is to search things out — Proverbs 25:2
Galileo said the purpose of man is to study nature and unveil the secret things of this world, but religion is to show man how to go to Heaven.
The Holy Spirit’s intention is to teach us how to go to Heaven. Science is to teach us how heaven goes — Galileo Galilei
That means you can be a scientist and be religious too.
https://www.youtube.com/watch?v=qAQL9gRmq34
https://www.oratoriosanfilippo.org/galileo-baronio-english.pdf