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
serg [7]
3 years ago
7

write the program or pseudocode algorithm that computes the product and average of three integers and display the results​

Computers and Technology
1 answer:
sweet-ann [11.9K]3 years ago
7 0

<u>Answer:</u>

<u><em>Algorithm: </em></u>

<em>Step 1: </em><em>Begin </em>

<em>Step 2: </em><em>Obtain the inputs – all the three integers </em>

<em>Step 3: </em><em>Calculate product using the formula “a*b*c” </em>

<em>Step 4: </em><em>Calculate sum and then with the help of sum calculate the average </em>

<em>Step 5: </em><em>Print the value of product and average </em>

<em>Step 6: </em><em>End </em>

<u>Explanation:</u>

<u><em>Program: </em></u>

<em>#include<stdio.h> </em>

<em>int main () { </em>

<em>    int a, b, c; </em>

<em>    printf(""Enter three numbers: ""); </em>

<em>    scanf(""%d %d %d"", &a, &b, &c); </em>

<em>    int sum = a + b + c; </em>

<em>    int product = a * b * c; </em>

<em>    float avg = sum / 3.0; </em>

<em>    printf(“Product = %d”, product”);  </em>

<em>    printf(""Sum = %d, Average = %f"", sum, avg); </em>

<em>    return 0; </em>

<em>} </em>

You might be interested in
In order to avoid slipping in the shop, your footwear should ___________.
dimaraw [331]

Answer:

Be sticky or not slippery

Explanation:

7 0
3 years ago
Read 2 more answers
almost every school or university has a or council or organization that works towards provision of providing education training
disa [49]

Answer:

In education, the term stakeholder typically refers to anyone who is invested in the welfare and success of a school and its students, including administrators, teachers, staff members, students, parents, families, community members, local business leaders, and elected officials such as school board members, city ...

Explanation:

6 0
3 years ago
Write a program that accepts a whole number as input, multiplies that number by 12, and then outputs the product
kenny6666 [7]

The program accepts a whole number as input, multiplies that number by 12, and then outputs the product

Explanation:

This program asks user to enter two integer numbers and displays the product.

The scanner class is used as input functions.

The code is shown below :  

import java.util.Scanner;

public class Demo {

public static void main(String[] args) {

Scanner scan = new Scanner(System.in);

System.out.print("Enter number: ");

int num1 = scan.nextInt();

scan.close();

int product = num1*12;

System.out.println("Output: "+product);

   }

}

5 0
4 years ago
Read 2 more answers
Why is wearable technology important?
BaLLatris [955]
If you are in war, Wearable Technology would provide Night Vision which would spot Hostile Soldiers in forests or in the dark.
8 0
3 years ago
We will pass in a value N. Write a program that outputs the complete Fibonacci sequence for N iterations. Important: If N is 0,
jasenka [17]

Answer:

The program written in Python is as follows

def fibonac(N):

    series = ""

    for i in range(0,N+1):

         series = series + str(i) + ","

   return series[:-1]

N = int(input("Number: "))

print(fibonac(N))

Explanation:

This line defines the function fibonac

def fibonac(N):

This line initializes variable "series" to an empty string

    series = ""

This line iterates through the passed argument, N

    for i in range(0,N+1):

This line determines the Fibonacci sequence

         series = series + str(i) + ","

Lastly, this line returns the Fibonacci sequence

   return series[:-1]

The main starts here

The firs line prompts user for input

N = int(input("Number: "))

This line prints the Fibonacci sequence

print(fibonac(N))

3 0
3 years ago
Other questions:
  • 1. Which of the following describes a way of memorizing a poem using a mnemonic device?
    15·1 answer
  • 11. If the following pseudocode were an actual program, what would it display:
    6·2 answers
  • You're familiar with the story of Hansel and Gretel, so when you decide to go exploring you always make sure to keep track of wh
    14·1 answer
  • True or False: It is illegal to park in a location that you block or create a hazard for other vehicles.
    11·2 answers
  • he Correct Coding Initiative (CCI) edits contain a listing of codes under two columns titled, "comprehensive codes" and "compone
    8·1 answer
  • Random letter of the alphabet for Python coding
    11·2 answers
  • Anna wants to keep information secure from offenders. Which software should she install on her computer to ensure Internet safet
    13·1 answer
  • What type of photography is represented by a photograph of a dog on a beach ?
    11·1 answer
  • Given the IPv4 address, 200.245.10.150/28, how many subnets are possible and how many hosts can be supported by each subnet?
    15·1 answer
  • Can someone please help me with this .
    11·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!