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

What will be the value of “sumtotal” when this code is executed?

Computers and Technology
1 answer:
Lelu [443]3 years ago
4 0

Answer:

2

Explanation:

if-else is the statement that is used for checking the condition and if the condition is True, then execute the statement otherwise not executed.

initially, the value of n1 = 3, n2 = 6, n3 = 2, sumtotal = 4.

after that, if statement checks for the condition.

3 != 4

condition is TRUE, then the statement sumtotal -= n3; will be executed.

write the statement in simple form:

sumtotal = sumtotal - n3;

so, sumtotal = 4-2 = 2.

after that, the program does not check the further and exit the if-else statement.

Therefore, the answer is 2.

You might be interested in
Why is a class an excellent representation of an abstract data type?
JulsSmile [24]

Answer:

 A class is an good representation of the abstract data type as it is represented independently. For implementing a class, it is use to specify the interface for an abstract class.

Class is one of the type of abstract data type for the objects that whose behavior is basically define by the set of operations and values. It is known as abstract as, it provide an implementation independently.

When the class is using in an abstract data type, then it refers as hidden representation of the data. In this modern era, class is use for the implementation of the abstract data type.

6 0
3 years ago
You entered the following line of code in IDLE.
AlexFokin [52]

Guess is a string. By default the input function returns string types.

8 0
3 years ago
Read 2 more answers
The United States Army retains a history of all equipment acquisition from approval of requirements through funding, authorizing
Mama L [17]

Answer:

A. data mart

Explanation:

Data mart refers to a structure for storing and retrieving data. Often times, the data mart is usually specific to a business line.

The data contained herein is also specific to a particular department and by so doing this facilitate easy isolation, use and development of the data.

The major advantage of creating data marts is for easy accessibility of data.

7 0
3 years ago
Write a program that takes a point (x,y) from theuser and find where does the point lies. The pointcan
agasfer [191]

Answer:

C++ Program .

#include<bits/stdc++.h>

using namespace std;

int main()

{

int x,y;//declaring two variables x and y.

string s;//declaring string s..

cout<<"enter x and y"<<endl;

cin>>x>>y;//taking input of x and y..

if(x>=0 &&y>=0) //condition for 1st quadrant..

cout<<"the point lies in 1st Quadrant"<<endl;

else if(x<=0 &&y>=0)//condition for 2nd quadrant..

cout<<"the point lies in 2nd Quadrant"<<endl;

else if(x>=0 &&y<=0)//condition for 3rd quadrant..

cout<<"the point lies in 3rd Quadrant"<<endl;

else //else it is in  4th quadrant..

cout<<"the point lies in 4th Quadrant"<<endl;

cout<<"enter n to terminate the program"<<endl;

while(cin>>s)//if the user has not entered n the program will not terminate..

{

   if(s=="n")

   {

       cout<<"the program is terminated"<<endl;

       exit(0);

   }

   cout<<"you have not entered n please enter n to terminate the program<<endl;

}

}

Explanation:

The above written program is for telling the point lies in which quadrant.I am first declaring two variables x and y.Then after that taking input of x and y after that checking in which quadrant the point lies.

Taking input of the string s declared earlier for program termination the program will keep running until the user enters n.

4 0
3 years ago
________ is a command-line utility installed in the windows\system32 folder that displays information about your windows version
Ne4ueva [31]
Im pretty sure its SystemInfo...... 
6 0
3 years ago
Other questions:
  • In which setting would you be least likely to find a full-time A/V technician?
    5·2 answers
  • Almost immediately after a server migration project, employees are complaining that they can't reach the Internet. You sit down
    8·1 answer
  • Using python:
    10·1 answer
  • Whats with the bot spamming customer care numbers...kinda annoying when im trying to help people.
    12·1 answer
  • The Curtis Publishing Company's early marketing research efforts mainly had to do with _____. people who drove automobiles peopl
    10·1 answer
  • Which of the following lines of code correctly defines a function called combine? OA define "combine(a, b, c)" as: B. define(com
    9·1 answer
  • ________ are the symbolic codes used in assembly language?​
    6·1 answer
  • What is the sequence of instructions performed to execute one program instruction
    13·1 answer
  • What are some examples of productions categorized as non-broadcast productions?
    6·1 answer
  • A(n) Blank______ database management system allows users to create, read, update, and delete data in a relational database. Mult
    9·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!