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
qaws [65]
2 years ago
7

write a C++ program that requires the user to enter two-digit positive and negative integers . The program counts the number of

occurrences of each integer . When the user enters a number greater than 100 or less than -100, the program should exit and print out the statistics of how many times each integer between [-9 and +9] occurred as well as how many numbers outside the range of [-9 to +9] occurred. A sample output of the program is given at the end.
Computers and Technology
1 answer:
ValentinkaMS [17]2 years ago
4 0

Answer:

Use GitHub it helps a lot

Explanation:

You might be interested in
Write a complete Java program called Rooter that gets a positive integer called "start" from the user at the command line and th
Nataly_w [17]

Answer:

The program in Java is as follows:

import java.util.*;

import java.lang.Math;

public class Rooter{

public static void main(String[] args) {

    Scanner input = new Scanner(System.in);

 int start;

 System.out.print("Start: ");

 start = input.nextInt();

 while(start<=0){

     System.out.print("Number must be positive\nStart: ");

     start = input.nextInt();  }

 while(start>=0){

     System.out.println(Math.sqrt(start));

     start--;  }

}

}

Explanation:

This declares start as integer

 int start;

This prompts the user for input

 System.out.print("Start: ");

This gets input for start

 start = input.nextInt();

The following is repeated until the user input is valid i.e. positive

<em>  while(start<=0){</em>

<em>      System.out.print("Number must be positive\nStart: ");</em>

<em>      start = input.nextInt();  }</em>

The following while loop prints the square root of each number till 0

<em>  while(start>=0){</em>

<em>      System.out.println(Math.sqrt(start));</em>

<em>      start--;  }</em>

4 0
2 years ago
AUPs ensure that an organization’s network and internet are not abused. Select 3 options that describe AUPs.
tigry1 [53]

AUPs often involves not going onto unauthorized sites or downloading certain content, not using the service to violate any law, and not connecting to unauthorized devices through the network.

<h3>What is AUP?</h3>

AUP stands for Acceptable Use Policy, which refers to a policy that regulates users when they access a corporate newtork.

<h3>How does an AUP regulates users?</h3>

Most AUPs imply:

  • Users can only access certain sites and dowloading specific content is forbidden.
  • The access to the internet or network cannot be used for criminal purposes.
  • Only authorized users can connect to the corporate network.

Learn more about AUP in: brainly.com/question/9509517

#SPJ1

8 0
2 years ago
In the Mouse Properties window, you can
levacccp [35]
B- You can adjust the mouse's double-click speed.

Some computer mouse software (depends on brand) will allow you to set new tasks for the mouse to perform.  Sometimes there are mice that have extra buttons that can be programmed to do certain tasks.
6 0
3 years ago
Drag the tiles to the correct boxes to complete the pairs.
professor190 [17]

Answer: James is all of the above

Explanation:

4 0
3 years ago
Matching parentheses. An math expression may have a number of parentheses like (, ), [, ], { and }. Each openning parenthesis (,
Solnce55 [7]
C++ Code

#include
using namespace std;

bool match(const char exp[],const int s)
{
// declare a character array to perform stack operations
char stack[s];

// declare top and initialize to -1 and flag to 0
int top=-1,i,flag=0;

// visit all characters in the expression string
for(i=0;i {
// if the character is [ or ( or { then push it into stack
if(exp[i]=='[' || exp[i]=='(' || exp[i]=='{')
{
top++;
stack[top]=exp[i];
}
// if the character is ] or ) or } then check conditions
else if(exp[i]==']' || exp[i]==')' || exp[i]=='}')
{
// check stack is empty or not
if(top!=-1)
{
// check all possible failure conditions
if(exp[i]==')' && (stack[top] == '{' || stack[top]=='['))
{
flag = 1;
break;
}
else if(exp[i]==']' && (stack[top] == '{' || stack[top]=='('))
{
flag = 1;
break;
}
else if(exp[i]=='}' && (stack[top] == '(' || stack[top]=='['))
{
flag = 1;
break;
}
top--;
}
else
{
flag=1;
break;
}
}
}
// after visiting all characters of expression string check if stack is not empty and flag is 1. if any one of the condition is true return false. otherwise return true

if(top>=0 || flag==1)
return false;
else
return true;
}

int main()
{

// declare character array to store expression
char exp[10000];
cout<<"Enter an Expression"<
// read expression from user
cin.getline(exp, 10000);
int s=0;

// find the length of the expression string
for(int i=0;exp[i]!='\0';i++)
{
s++;
}

// call the match function
bool status = match(exp,s);

// print the result based on value returned by match() function
if(status == 1)
cout<<"true"< else
cout<<"false"<
}


Sample Input/Output is attached

3 0
2 years ago
Other questions:
  • Kurt is editing a table in his powerpoint that displays accounting formulas and when to use them. he wants to remove the table s
    15·1 answer
  • The automotive system that connects the engine and the transmission to the wheels is called the
    14·1 answer
  • What do you call the process of translating statements written by a developer? What is the result of this process?
    6·1 answer
  • What is the definition of digital literacy?
    7·2 answers
  • Is the following a true statement in our world? Why or why not?
    13·1 answer
  • which program monitors the computer by looking for known trouble makers as well as suspicious behavior​
    11·1 answer
  • Wanna play pubg<br><br><br>ill send u my id​
    5·2 answers
  • Virus program do not replicate themselves true or false one word answer only​
    15·2 answers
  • What is the best way of farming exotics in destiny?
    12·2 answers
  • You want a cable that could be used as a bus segment for your office network. The cable should also be able to support up to 100
    5·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!