I've recently come across a situation where scammers are generating (bitcoin) addresses that have the same starting and ending characters. This is concerning as many people, including myself, often check the starting and ending characters of an address when making a transfer. Furthermore, many wallets hide the middle part of the address with an ellipsis for a cleaner UI, making this scam even more effective.
I understand that a collision in bitcoin addresses is virtually impossible due to the vast address space, and there are already several discussions on this topic. However, I am interested in a slightly different question: What is the probability of someone being able to generate a Bitcoin address that has the same last four characters? Or, to take it a step further, what is the probability of generating an address that has the same first four and last four characters?
I am looking for a detailed explanation of how to calculate these probabilities, as well as the results of these calculations. Any help would be greatly appreciated.