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
Brut [27]
3 years ago
13

What is the output of the following C++ program?

Computers and Technology
1 answer:
Natalija [7]3 years ago
5 0

Answer:

0 This is base class

Derived class: 9

16 Hello Base

Explanation:

The header files #include <iostream> #include <string> was wrongly included in the question this had to be edited.

After properly editing the programme to remove errors, the expected output when you run the code is:

0 This is base class

Derived class: 9

16 Hello Base

You might be interested in
Assume that the int variables i, j and n have been declared, and n has been initialized. Write code that causes a "triangle" of
makvit [3.9K]

Answer:

The code that will cause the triangle of  asterisks is given by;

for (i=1; i<=n; i++){

for (j=1; j<=i; j++)

cout << "*";

cout << "\n";

}

Explanation:

6 0
4 years ago
Write an assembly program to find the largest item in an array and store it in a variable named MAXIMUM. Hint: Use both Jump and
Gekata [30.6K]

Use the knowledge of computational language in C++ to write the a code assembly program to find the largest item.

<h3>How to write a maximum function in C++?</h3>

To make it simpler the code is described as:

<em>#include<bitd/stdc++.h></em>

<em>Using namespace std;</em>

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

<em>Int arr[10]={10, 2, 23, 45, 21, 11};</em>

<em>Int min=INT_MAX;</em>

<em>Int max=INT_MIN;</em>

<em>for(int i=0;i<10;i++)</em>

<em>If(min<arr[i])min=arr[i];</em>

<em>for(int j=0;j<10;j++)</em>

<em>if(max>arr[j])max=arr[j];</em>

<em>Cout<<max<<” “<<min<<endl;</em>

<em>return 0;</em>

See more about C++ code at brainly.com/question/19705654

7 0
2 years ago
Consider the following code:
Deffense [45]

Answer:

The output of C is 102.

100 + 1 + 1 = 102

8 0
3 years ago
What is Shay doing if she makes the most out of her work sessions by displaying and working with several programs all at once?
harkovskaia [24]
This is an important function called MULTITASKING
6 0
4 years ago
You're a ticket agent for a commercial airline and responsible for checking the identification for each passenger before issuing
algol13

Answer:

Follows are the code to this question:

import java.util.*;//import package for user input  

public class Main //defining class  

{

  public static void main(String[] as)//main method

  {

      boolean x,y,z;//defining boolean variable

      Scanner ox= new Scanner(System.in);//create Scanner class object for user input

      System.out.println("input value: "); //print message  

      x=ox.nextBoolean();//input value

      y=ox.nextBoolean();//input value

      z=ox.nextBoolean();//input value

      System.out.println("Output: ");//print message

      System.out.println(x || (y &&z));//use print method to check value and print its value  

  }

}

Output:

1)

input value:  

true

false

false

Output:  

true

2)

input value:  

false

true

true

Output:  

true

3)

input value:  

false

false

false

Output:  

false

Explanation:

In the given code, inside the class three boolean variable "x,y, and z" is declared, that uses the scanner class for input the value from the user end, and in the next print, the method is declared, that uses " OR and AND" gate for calculating the input value and print its value.

In the AND gate, when both conditions are true. it will print the value true, and in the OR gate, when one of the conditions is true, it will print the value true.  

3 0
4 years ago
Other questions:
  • Why is it important for a Support Agent to understand and follow their company’s standardized case lifecycle roadmap? (Select 2)
    12·1 answer
  • Give two reasons why mobile internet may not be available everywhere. ​
    11·1 answer
  • How do you adjust the shear of a shape?
    10·2 answers
  • What is displayed in the alert dialog box after the following code is executed? var items = 3; for (var i = 1; i &lt;= items; i+
    8·1 answer
  • A client contacted you to request your help in researching and supplying the hardware necessary to implement a SOHO solution at
    5·1 answer
  • Today when Dylan turned on his computer, he noticed that the monitor was very dim. He could still see the desktop icon and text.
    15·1 answer
  • Which one of the following analog VOM ranges would be selected to measure a DC
    13·1 answer
  • 3. Comparing the Utopian and dystopian views of Technology according to Street (1992) which one in your view is more applicable
    14·1 answer
  • What do you understand by the terms:<br> I)input<br> ii)process<br> iii)storage<br> iv)output
    15·1 answer
  • A type of user interface that features on- screen objects, such a menus and icons, manipulated by a mouse.
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!