bone8765 bone8765
  • 03-06-2021
  • Computers and Technology
contestada

Write a function definition for a function which takes one parameter and returns twice that parameter

Respuesta :

MrRoyal
MrRoyal MrRoyal
  • 03-06-2021

Answer:

The function in python is as follows:

def twice(num):

   return 2 * num

Explanation:

This defines the function; The function receives num as its parameter

def twice(num):

This returns twice of num

   return 2 * num

Answer Link

Otras preguntas

Which of the following is an interjection? A. Hunting B. Wow C. Is D. Acrimonious
Carbohydrates are the main building block of tissues and organs. a. True b. False
Compose un petit poeme.Comence par: C est ma chambre.Dans...
What is the retail price of a couch at a furniture store that has a wholesale price of $115 and is marked up by 75 percent?
What was a main difference between french conservatives and liberals following the congress vienna
each type of mineral has a chemical composition that is what
What us military branch was formed in 1947 marines, coast guard, air force?
When Queen Elizabeth I says that she has “the heart and stomach of a king,” she means that —?
Why do both plants and solar panels provide renewable energy?
in traditional India the caste system and the Hindu beliefs in karma and dharma most directly resulted in?