1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
kirill115 [55]
2 years ago
15

Def area(length, height):

Computers and Technology
1 answer:
Basile [38]2 years ago
6 0

Following are the <em><u>python complete code </u></em>to calculate the area:

Program Explanation:

  • Defining a method "area" that takes two variables "length, height" in the parameters.
  • Inside the method, a variable "area" is declared that calculates the area by multiplies "length and width".
  • After calculating the area a return keyword is used that returns its value.
  • Outside the method, a print method is declared that calls the area method by accepting value into its parameters.

Program:

def area(length, height):#defining a method area that takes two parameters "length, height"  

  area = length * height#defining a variable area that calculates the area by multiplies length and width  

  return area#using return keyword that returns area value  

print(area(9,8))#using a print method that calls area method by accepting the value  

Output:

Please find the attached file.

  • <u>In this code, the </u><u>method call</u><u> is missing therefore, the final answer is</u> "Option A".

Learn more:

brainly.com/question/24819022

You might be interested in
To insert text from a separate file into your Word document
vagabundo [1.1K]
Copy and paste? i think.
3 0
3 years ago
When you press the ____ key without entering any text after the automatic bullet character, Word turns off the automatic bullets
Amiraneli [1.4K]
Enter key it will atumatically bullet
7 0
3 years ago
​______________________ is a general security term that includes computer​ viruses, worms, and trojan horses.
VashaNatasha [74]
Malware
-------------------
6 0
3 years ago
Write a method reverse that takes an array as an argument and returns a new array with the elements in reversed order. Do not mo
mr Goodwill [35]

Answer:

public class ArrayUtils

{

//function to reverse the elements in given array

public static void reverse(String words[])

{

//find the length of the array

int n = words.length;

//iterate over the array up to the half

for(int i = 0;i < (int)(n/2);i++)

{

//swap the first element with last element and second element with second last element and so on.

String temp;

temp = words[i];

words[i] = words[n - i -1];

words[n - i - 1] = temp;

}

}

public static void main(String args[])

{

//create and array

String words[] = {"Apple", "Grapes", "Oranges", "Mangoes"};

//print the contents of the array

for(int i = 0;i < words.length;i++)

{

System.out.println(words[i]);

}

//call the function to reverse th array

reverse(words);

//print the contents after reversing

System.out.println("After reversing............");

for(int i = 0;i < words.length;i++)

{

System.out.println(words[i]);

}

}

Explanation:

4 0
2 years ago
Consider two vectors that are NOT sorted, each containing n comparable items. How long would it take to display all items (in an
Darina [25.2K]

Answer:

The correct answer to the following question will be "Θ(​n​2​)

". The further explanation is given below.

Explanation:

If we're to show all the objects that exist from either the first as well as the second vector, though not all of them, so we'll have to cycle around the first vector, so we'll have to match all the objects with the second one.

So,

This one takes:

= O(n^2)

And then the same manner compared again first with the second one, this takes.

= O(n^2)

Therefore the total complexity,

= Θ(​n​2​)

7 0
3 years ago
Other questions:
  • SOMONE TELL ME THERE ROBLOX USER NAME AND DO U PLAY IT!!!!! MINE IS Borutouzimaki2133
    9·2 answers
  • Type the correct answer in the box. Spell all words correctly.
    9·1 answer
  • What are the advantages of repeating a header row? check all that apply
    14·1 answer
  • Carson's supervisor has asked him to review a variety of portable computers for possible purchase for their company's employees.
    13·1 answer
  • Summary In this lab, you declare and initialize variables in a C++ program. The program, which is saved in a file named NewAge.c
    5·1 answer
  • Do the shape of a sign gives you a clue about the information contained on the sign
    7·1 answer
  • A ________ is a self-contained program that spreads through a computer network by exploiting security holes in the computers con
    9·1 answer
  • Linda wants to apply for a job in a company of her choice. Which information would her potential employers likely review in her
    10·2 answers
  • Write a static method reOrder56(int[] nums) that return an array that contains exactly the same numbers as the given array, but
    10·1 answer
  • What method is used in the following line of code to associate clicking the left button with the event handler "clickSingle"?
    9·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!