nerdexam
GIAC

GPYC · Question #64

Which of the lambda definitions of the function some_code is equivalent to the following function definition? def some_code (invalue): outvalue = invalue * 2 return outvalue

The correct answer is A. some_code = lambda outvalue:invalue*2. You've hit your limit · resets 1pm (America/New_York)

Python Fundamentals & Command Line Tools

Question

Which of the lambda definitions of the function some_code is equivalent to the following function definition? def some_code (invalue): outvalue = invalue * 2 return outvalue

Options

  • Asome_code = lambda outvalue:invalue*2
  • Bsome_code = lambda invalue:outvalue*2
  • Csome_code = lambda invalue:invalue*2
  • D

How the community answered

(24 responses)
  • A
    88% (21)
  • B
    8% (2)
  • C
    4% (1)

Explanation

You've hit your limit · resets 1pm (America/New_York)

Topics

#lambda functions#function definitions#Python syntax#anonymous functions

Community Discussion

No community discussion yet for this question.

Full GPYC Practice