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
frosja888 [35]
3 years ago
8

Write an application that asks a user to type an even number or the sentinel value 999 to stop. When the user types an even numb

er, display the message "Good job!" and then ask for another input. When the user types an odd number, display an error message, "x is not an even number", and then ask for another input. When the user types the sentinel value 999, end the program
Computers and Technology
2 answers:
Alisiya [41]3 years ago
6 0

Answer:

int value;

while(1){

scanf("%d\n", &value);

if(value == 999)

break;

if(value%2 == 0)

printf("Good job");

else if(value%2 == 1)

printf("%d is not an even number", value);

}

Explanation:

I am going to write a C code for this.

The while(1) runs until the break command. So

int value;

while(1){

scanf("%d\n", &value);

if(value == 999)

break;

if(value%2 == 0)

printf("Good job");

else if(value%2 == 1)

printf("%d is not an even number", value);

}

yan [13]3 years ago
3 0

Answer:

 do{

    std::cout << "input an even number: ";

    std::cin >> n;

    even=n%2;

    if (even==0)

    std::cout << "Good job!\n";

    else

    std::cout << n <<" is not an even number\n";

    }while(n!=999);

Explanation:

#include <iostream>

#include <string>

int main()

{ int n=0,even;

 do{

    std::cout << "input an even number: ";  //print on screen to input the number

    std::cin >> n;  //put that value on n variable

    even=n%2;

    if (even==0)  //if even is zero the number is even

    std::cout << "Good job!\n";

    else  //if even is not zero the number is odd

    std::cout << n <<" is not an even number\n";

    }while(n!=999);  // we will repeat the proccess while n is diffrente from 999

}

You might be interested in
Which step should Rupa take?
PilotLPTM [1.2K]

Complete Question:

Rupa would like to quickly insert a table into her document without having to worry about formatting the data in the table. Which step should Rupa take?

Group of answer choices.

A. Insert tab, Tables group, Draw Table option

B. Insert tab, Tables group, Insert Table option

C. Insert tab, Tables group, Quick Tables option

D. none of the above

Answer:

C. Insert tab, Tables group, Quick Tables option

Explanation:

Microsoft Word refers to a word processing software application or program developed by Microsoft Inc. to enable its users to type, format and save text-based documents.

In Microsoft Word 2019, the users are availed with the ability to edit the word document in the following view type;

I. View Mode.

II. Print Mode.

III. Drift Layout.

Quick tables refers to the pre-formatted or pre-created stored in building blocks galleries that are easily accessible to the end users at any time.

In this scenario, Rupa would like to quickly insert a table into her document without having to worry about formatting the data in the table. The steps which Rupa should take are click on Insert tab, Tables group and then select the Quick Tables option.

6 0
3 years ago
Your ghost hunting group is recording the sound inside a haunted Stanford classroom for 20 hours as MP3 audio files. About how m
Mademuasel [1]

Answer:

1.152 GB if it will be at 128 kbps quality

Explanation:

So, let's say you choose your mp3 be 128 kbps (kilobits per second).

One byte is 8 bits. So 128 kbps = 16 kilobytes per second.

There is 60*60 seconds in one hour. So 16*60*60 = 57.6 megabytes per hour

Multiply by 20 hours to get your answer: 57.6*20 = 1152 MB = 1.152 GB.

3 0
3 years ago
When adding clip art to a slide you are limited to the pictures stored on your computer?
77julia77 [94]
The answer is No.  <span>When adding clip art to a slide you are not limited to the pictures stored on your computer.  </span><span>We are not limited to using clip art from our computer. Any clip art can be used, but if it is from another source, it must first be saved to your computer as a </span>file<span>. </span>
8 0
3 years ago
5.   Which of the following attributes of a website indicates a more reliable source for information?
Leona [35]
The answer would be B because ".edu" stands for education and it shows there was a source for the information
5 0
3 years ago
What are the means of hardware security?​
sdas [7]

Answer:

Hardware security is vulnerability protection that comes in the form of a physical device rather than software that is installed on the hardware of a computer system. ... Common examples include hardware firewalls and proxy servers.

Explanation:

Thank you

5 0
2 years ago
Read 2 more answers
Other questions:
  • A(n) __________ is a set of technologies used for exchanging data between applications and for connecting processes with other s
    14·2 answers
  • Your friend sees an error message during Windows startup about a corrupted bootmgr file. He has another computer with a matching
    12·1 answer
  • Lux Ladies, Inc., is a company that specializes in expensive and unusual gifts for all occasions. It keeps a large file of infor
    11·1 answer
  • What is the first step to creating a PivotTable?
    11·1 answer
  • Are one of the greatest features of Photoshop that allow nondestructive editing of images.
    6·1 answer
  • Guys Do you know about e-waste recycling well ?
    9·2 answers
  • Which of the following activities are performed by computer programmers? Choose all that apply.
    5·1 answer
  • What is the capacity of a disk with two platters, 10,000 cylinders, an average of 400 sectors per track, and 512 bytes per secto
    9·1 answer
  • Read integers from input and store each integer into a vector until -1 is read. Do not store -1 into the vector. Then, output al
    11·1 answer
  • Artificial intelligence (AI) and machine learning are especially important during which security information and event managemen
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!