answer.
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
Vesnalui [34]
2 years ago
14

Write an if-else statement to describe an integer. Print "Positive even number" if isEven and is Positive are both true. Print "

Positive number" if isEven is false and is Positive is true. Print "Not a positive number" otherwise. End with newline.
Computers and Technology
1 answer:
Nina [5.8K]2 years ago
6 0

Answer:

C code explained below

Explanation:

#include <stdio.h>

#include <stdbool.h>

int main(void) {

int userNum;

bool isPositive;

bool isEven;

scanf("%d", &userNum);

isPositive = (userNum > 0);

isEven = ((userNum % 2) == 0);

if(isPositive && isEven){

  printf("Positive even number");

}

else if(isPositive && !isEven){

  printf("Positive number");

}

else{

  printf("Not a positive number");

}

printf("\n");

return 0;

}

You might be interested in
The web development team is having difficulty connecting by ssh to your local web server, and you notice the proper rule is miss
joja [24]

Answer:

Option b (Port 22) seems to the appropriate choice.

Explanation:

<u>Below seem to be some measure you should take to correct this mistake.</u>

  • Verify whether Droplet's host IP address seems to be right.  
  • Verify existing connection supports communication over all the utilized SSH port. Any access points can be able to block port 22 and sometimes customized SSH. For illustration, you could do this by checking different hosts who used the same port, using only a recognized working SSH connection. These could help you identify unless the current problem is not particular to clients' Droplet.
  • Authenticate the Droplet configuration settings. Verify that they're not being configured to DROP 's preferred policy, and do not apply the port to require connectivity.

The SSH server also operates on port 22, by default.  

Other choices don't apply to the specified scenario. So that the argument presented above will be appropriate.

7 0
2 years ago
All the employees of Delta Corporation are unable to access the files stored in the server. What do you think is the reason behi
CaHeK987 [17]
C serve crash hope this is correct
5 0
2 years ago
Shirley was unsure about what career to go into. Her high school counselor suggested a personal assessment to point out Shirley’
Alex73 [517]
<span>I think that she would be well suited in going into law enforcement or fire fighting. Since she loves to stay active and is cool under pressure, both of those jobs would be very well suited for her personality. Those 2 jobs demand to stay cool into delicate situations. Also, she would be able to come in to help people in need.</span>
4 0
2 years ago
Read 2 more answers
Your network administrator finds a virus has been successfully inserted into the network software. The virus itself is now consi
Svetlanka [38]

Answer: Vulnerability of

Explanation:

The network administrator was able to identify that virus before it led to denial of service to users. Since it has been discovered, it is no longer a threat as measures will be taken to eliminate it. But a virus that was successful uploaded shows how vulnerable the system is or how bad the security protections put in place are. Steps has to be taken to ensure it does not reoccur.

7 0
2 years ago
Read 2 more answers
What might be one reason why a stock becomes more valuable over time
Nikolay [14]
1. The General Market is Down This is for the most part the most evident reason that a stock is underestimated and happens when the large scale perspective of the economy is poor. It is helpful for financial specialists to have some fundamental apparatuses to esteem the general market so they can get ready as the market progresses toward becoming underestimated.
7 0
2 years ago
Other questions:
  • Write the printItem() method for the base class. Sample output for below program:
    8·1 answer
  • Which of the registration patterns is best suited for complex architecture? A. Client side discovery pattern B. Third party regi
    13·1 answer
  • 7.8.1: Function pass by reference: Transforming coordinates. Define a function CoordTransform() that transforms the function's f
    6·1 answer
  • To play game, go inside the Grand Theft Auto V folder and right click and runGTAVLauncher as administrator.If you get any missin
    5·1 answer
  • Se dau lungimile a N cuvinte (0 &lt; N ≤ 5 000), formate din cel puțin un caracter. Să se afișeze lungimea minimă necesară R a u
    14·1 answer
  • Modify the closest pair of points algorithm so that the separating line L now separates the first n/4 points (sorted according t
    14·1 answer
  • Quantum units of information deploy the properties of entanglement and ____ to offer exponentially greater computing power.
    9·1 answer
  • When drivers have no control over their driving environment and are stuck in traffic, the lack of control over the traffic event
    13·1 answer
  • Checkpoint 10.43 Write an interface named Nameable that specifies the following methods: _______{ public void setName(String n)
    12·1 answer
  • Which is the correct notation to specify the following inheritance?
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!