smilequi3272 smilequi3272
  • 04-07-2019
  • Computers and Technology
contestada

Write a recipe that stores the sum of the numbers 12 and 33 in a variable named sum. Have your recipe display the value stored in sum.

Respuesta :

PhantomWisdom PhantomWisdom
  • 12-07-2019

Answer:

#include<iostream>

using namespace std;

int main(){

   int sum = 12+33;

   cout<<"The sum is: "<<sum<<endl;

}

Explanation:

First include the library iostream in c++ program for input/output.

Then, create the main function and declare the variable sum as integer type and store the sum of two given values.

After that, display the result store in the sum variable on the screen by using the instruction cout.

Answer Link

Otras preguntas

Will spent $40 at the fair. It cost $20 to get in the fair and $0.50 per ticket to ride the rides. How many tickets did Will buy? A. 40 B. 20 C. 120 D. 30
“What was the goal of humanism”
Describe the Stages of Infection
where is the cadenza in Shotstakovich's Cello Concerto No. 1
A particular fruit's weights are normally distributed, with a mean of 372 grams and a standard deviation of 26 grams. If you pick 36 fruit at random, what is th
Solve the equation In (x-4)=1
Does someone know this
A quadratic function has zeros -7 and 9. What are the linear factors of the function? (x-7)(x+9) 0 (x-7)(x-9) X+7)(x+9) 0 (x+7) (X-9)
Describe the Color Yellow?
The quote below characterizes Sonny as... "It was as though Sonny were some sort of god, or monster. He moved in an atmosphere which wasn't like theirs at all.