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
Alja [10]
3 years ago
10

Write a small program basic c++, that defines a negative integer (between ‐1 and ‐255), converts it to a positive value and then

displays it on the console window.
Computers and Technology
1 answer:
ANEK [815]3 years ago
4 0

Answer:

#include <iostream>

using namespace std;

int main() {

int a=-156;//negative integer between -1 and -255.

a*=-1;//multiplying a to -1 so that it can become positive.

cout<<a;//printing a.

return 0;

}

Explanation:

The above written program is in C++ and in the program an integer a is defined with a negative value in the program it is -156.Then to convert it to positive integer we have to multiply a to -1 after that printing the value of a on the screen.

You might be interested in
Que significa el término Informática?
AleksandrR [38]

La informática es el estudio de la estructura, el comportamiento y las interacciones de los sistemas computacionales naturales y diseñados. La informática estudia la representación, el procesamiento y la comunicación de información en sistemas naturales y de ingeniería

6 0
3 years ago
The means by which an operating system or any other program interacts with the user is called th
natulia [17]
Networking capabilities of a computer
7 0
3 years ago
For this exercise, you are going to create a part of an Animal hierarchy. Unlike some of our examples and the previous exercises
kati45 [8]

Answer:

vehicle super class 9.1.4

Explanation:

So you need to create a super class containig all the animals use the class above for referance

5 0
3 years ago
Black box testing is the practice of writing tests without knowing the implementation of the code you're testing. White box test
Lelu [443]

Answer:

<u>First test:</u> Give a list of disordered numbers to the sorting algorithm an examine if the output is correctly sorted.

<u>Second test:</u> Give a list of ordered numbers to the sorting algorithm an analyze if the output is still correctly ordered.

<u>Third test:</u> Give a list of ordered numbers and some non-numeric values to the sorting algorithm and check how is managed the exception in case of error or if the output is correctly ordered.

6 0
3 years ago
Nothin to see here just browsin
velikii [3]

Answer:

What????

What does that mean??????????????????????????????????

4 0
3 years ago
Other questions:
  • Using the _______ list, you can select the number of photos that will appear on each slide.
    14·1 answer
  • . char values are surrounded by _____ quotes
    15·1 answer
  • Differentiate between Software as a service, platform as a service and infrastructure as a service.
    14·1 answer
  • What is the meaning of 4 8 15 16 23 42?
    14·1 answer
  • What is the other name of the horizontal column graph
    9·1 answer
  • I have been charged for brainly plus yet I still have to watch ads why? What do I do?
    12·2 answers
  • Please describe the role of games in modern society!
    5·2 answers
  • Carlos has become pretty efficient at using the Word Processor but he takes time to use the menu each time he saves, prints and
    12·1 answer
  • Write the technical terms for the following statements: The repeated working capacity of computer.
    15·1 answer
  • My assignment asks me to write a python program using if, elif, and else that takes a user's salary and calculates the tax based
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!