To give you a Python example, it encourages stuff like:
def send_email(recipients, contents):
if type(recipients) == str:
send_one_email(recipients, contents)
else:
for recipient in recipients:
send_one_email(recipient, contents)
That is a flavour of convenience that people commonly implement in Python. People like it because it allows both send_email("tome", contents)
and send_email(["tome", "mlthoughts2018"], contents)
and saves them from typing two square brackets. The problem is when you call send_email(u"tome", contents)
It tries to email "t", "o", "m", and "e". This kind of stuff is endemic in Python. Yes, this did happen in practice in a company I worked for (a company that was responsible for trading hundreds of millions of dollars of securities every day). Call the programmers exceptionally bad if you like, but they were among the brightest minds graduating in my country. It was Python that allowed them to be sloppy.