QuestionQ205Verified/Functions and ExceptionsCopy linkReport a problemAsk AstroTutorSave questionWhich of the following lines correctly begins the definition of a function with no parameters?Adef fun:Bdef fun():Cfun function():Dfunction fun():Show AnswerAnswerExplanationPython defines functions with def, a function name, parentheses containing the parameter list, and a trailing colon. A parameterless function still requires empty parentheses: def fun():.Show comments0Show commentsCommunity DiscussionNo comments yet. Be the first to start the discussion!
Community Discussion