Reputation: 3632
maybe this question is a little basic, but I'm reading the official docs in python:
ZipFile.extractall([path[, members[, pwd]]])
But I don't understand what the [] means?
Thanks,
Upvotes: 1
Views: 573
Reputation: 143047
[]
means that these are optional arguments that can be supplied to the function. The documentation will mention default values used otherwise.
Simple example using open():
open(name[, mode[, buffering]])
The filename is required, but mode and buffering are optional. The default mode for opening a file is read, so open(filename, 'r')
is equivalent to open(filename)
. For buffering
it states: "If omitted, the system default is used"
Upvotes: 17