Give syntax of the setdefault() method.
Answer:
Syntax of setdefault method is:
dict.setdefault(key [,default=None])
where,
- key = the key to be searched
- default = the value to be returned if the key is not found.
Learn in your speed, with individual attention - Teachoo Maths 1-on-1 Class