mining theory – Probability of finding a valid block


Today I learned that for BTC, the probability of a hash being valid is approximately 1/(D*2^32), whereas D denotes to the difficulty. I was wondering if this is also the case for other cryptocurrencies or if this is something specific to BTC or the SHA-256 hash algorithm? If it is different for other cryptocurrencies, are there similar formulas for the probability of a hash being valid?