Keyword arguments example.
|
|
def generateWebsite( name, url = "www.navioo.com",Flash = "no", CGI = "yes" ): print "Generating site requested by", name, "using url", url
if Flash == "yes": print "Flash is enabled"
if CGI == "yes": print "CGI scripts are enabledn" print
generateWebsite( "navioo" )
generateWebsite( "navioo", Flash = "yes", url = "www.navioo.com" )
generateWebsite( CGI = "no", name = "Prentice Hall" )
|
|
|
|
|
Related Scripts with Example Source Code in same category :
-
-
|
|