mimemultipart

Why are we using Square Brackets in python to access MIMEMultipart() components like ['From'], ['To'] for sending email using python?

Why are we using Square Brackets in python to access MIMEMultipart() components like ['From'], ['To'] for sending email using python? Question: In a python code, which is sending an email using "smtplib" and "MIMEMultipart" libraries, I got a doubt on, why we are using "square brackets" for [‘From’], [‘To’] and [‘Subject’] when referring to "MIMEMultipart …

Total answers: 1