Fire up Electrum (a portable executable/binary is good enough, regardless of OS), open the console tab and
getbalance('3ERBHeQ9SENDcsbmZMBTCFvY1LfGiCMEH8')
does what you are looking for. Since Electrum is native Python, it is very "scriptable" too.
That's the good news. The bad news is that it will never work for what you probably want to achieve: scan "all" public addresses, hoping to strike gold.
Please don't hammer the Electrum network with a gazillion pointless requests. If you need 10 or 20 lookups a day, sure. If more than that, do it offline with a recently updated list.