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
lana [24]
4 years ago
8

toThePowerOf is a function that accepts two int parameters and returns the value of the first parameter raised to the power of t

he second. An int variable cubeSide has already been declared and initialized. Another int variable, cubeVolume, has already been declared. Write a statement that calls toThePowerOf to compute the value of cubeSide raised to the power of 3, and store this value in cubeVolume.
Computers and Technology
1 answer:
zlopas [31]4 years ago
4 0

Answer:

cubeVolume = toThePowerOf(cubeSide, 3);

Explanation:

The line above accomplishes the task of calling the function toThePowerOf(). We are told in the question that the method accepts two int parameters these integer parameters are given as cubeSide and 3. They are passed as arguments when the method is called. The result of the function's computation is then assigned/stored to the the variable cubeVolume.

You might be interested in
Jordan just wrote a secret message program in python that converts the number 7,095 to 1s and 0s. Which number system is Jordan
nevsk [136]

Answer:

Binary

Explanation:

Binary code is code that only entails 1s and 0s

7 0
3 years ago
Read 2 more answers
. Use one command to create a /sales directory with the permissions of 770
mars1129 [50]

Answer:

mkdir -m 770 sales

Explanation:

The command mkdir is used to create a directory and the attribute or flag

-m is used to  assign permissions on create a folder.

Example:

mkdir -m 770 sales

Create a folder with permissions 770 with name sales

7 0
3 years ago
A command is
Alona [7]

Answer:

D

Explanation:

4 0
3 years ago
Write the definition of a function named quadratic that receives three double parameters a, b, c. If the value of a is 0 then th
podryga [215]

Answer:

Following are the program in the C++ Programming Language.

#include <iostream> //header file

#include <cmath> //header file

using namespace std; //namespace

//define function

void quadratic (double a, double b, double c)

{

 double x,y; //set double type variables

 //check a==0

 if (a==0)

 { //then print message

   cout << "no solution for a=0";

 }

 //check if solution is less than 0

 else if ((b*b - 4*a*c) < 0)

 { //print message

   cout << "no real solutions";

 }

 //otherwise

 else

 {//solve the following quadratic equation

   x = (-b + sqrt( b*b - 4*a*c)) /(2*a);//in term of x

   y = (-b - sqrt(b*b - 4*a*c)) / (2*a);//in term of y

   //check x is greater than y

   if (x > y){

     cout<<x; //print the value of x

   }

   //otherwise

   else{

     cout<<y;//print the value of y

   }

 }

}

//define main method

int main() {

 //set double type variables and assign their value

 double x=10, y=50, z=-205;

 //call the function

 quadratic(x,y,z);

}

<u>Output</u>:

2.67204

Explanation:

Here, we define a function "quadratic" and pass three double data type variables i.e., "a", "b" and, "c" inside the function.

  • Set two double type variable i.e., "x", "y".
  • Set the if conditional statement and check the conditions is the variable a is equal to the 0 then, print the message or check another condition is the solution of the equation "b*b - 4*a*c" is less than 0, then print the message.
  • Otherwise, solve the quadratic equation in terms of the variable x or the variable y.
  • Again check the condition inside the else part is the variable x is greater than the variable y then, print the value of x otherwise print the value of y.

Finally, we define the main function inside it we set three double type variables i.e., "x", "y" and, "z" and initialize value 10, 50 and, -250 then, call the function and pass the variables x y z in its parameter.

6 0
4 years ago
Which of the following is an example of self-awareness?
DENIUS [597]
Are you sure this is the right subject
4 0
3 years ago
Other questions:
  • The Sentence below me is true. <br><br><br> The Sentence above me is false
    13·1 answer
  • Which of the following is not anadvantage of simulation?
    14·1 answer
  • NOTE: in mathematics, the square root of a negative number is not real; in C therefore, passing such a value to the square root
    15·1 answer
  • Assignment 1 silly sentences
    12·1 answer
  • Ms. Myers commented that _____ she slept in at the hotel was better than _____ she slept in at home.
    7·1 answer
  • What is the purpose of the domain name? The domain name is an example of a service provider. The domain name .gov.nz is an examp
    15·2 answers
  • Lester has to create an app that can support offline data and rich media content such as audio and video. In which programming l
    15·1 answer
  • Anyone follows abhay​
    10·1 answer
  • ASAP NEED HELP ASAP NEED HELP ASAP NEED HELP ASAP NEED HELP ASAP NEED HELP ASAP NEED HELP ASAP NEED HELP ASAP NEED HELP​
    6·2 answers
  • What is a variable in programming?
    10·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!