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
oksian1 [2.3K]
3 years ago
5

What is the output of intb= 4+ 6 /2 Systemoutprintln (b)

Computers and Technology
1 answer:
uysha [10]3 years ago
5 0

Answer:

Command: Systemoutprintln (b)

Output: 7

Explanation:

To solve this problem, we must take into account the precedence of operation.

The division takes precedence before the addition, so we must divide before we add for b.

So

int b = 4 + 6/2 = 4 + 3 = 7.

So

Command: Systemoutprintln (b)

Output: 7

You might be interested in
The "network of networks," consisting of LANs (Local Area Networksnetworks connecting two or more computers, usually within the
irina1246 [14]

Answer:

Internet

Explanation:

Internet is very often called the network of networks, creating a bridge between many networks and joining larger networks to another.

5 0
3 years ago
Located toward the right of the status bar and contains buttons for zooming the display in and out
Flauer [41]
The answer is the view area
3 0
3 years ago
Imagine that you need to prepare for three end-of-term tests. What steps will you take to make sure your study time is well spen
ziro4ka [17]

Answer:

I will also choose a good study area and copy them and paste it

4 0
2 years ago
What is output by the following line of code?
astraxan [27]

Answer:int x = 5;

if(x < 5)

cout << "line 1 ";

cout << "line 2";

A. line 1 line 2 B. line 1 C. line 2

D. line 1 E. line 1line 2

line 2

2. What would be output by the following code? _______

int x = 0;

while(x < 5)

{

cout << x << " ";

x++;

}

A. 0 1 2 3 4 5 B. 1 2 3 4 5 C. 0 1 2 3 4

D. 0 E. 0 0 0 0 0

3. After execution of the following code, what will be the value of input_value if the value 3 is entered at the keyboard at run time? ________

cin >> input_value;

if (input_value > 5)

input_value = input_value + 5;

else if (input_value > 2)

input_value = input_value + 10;

else

input_value = input_value + 15;

a. A. 8

b. B. 13

c. C. 18

d. D. 0

e. E. 5

4. What would the user see displayed on the screen after the following lines of code are executed?¬¬________

int i = 6;

if (i == 10)

cout << “value: “ << i;

else

cout << "hmmm";

A. value: i B. value: 10

C. hmmm D. value: ihmmm

E. value: 10

Hmmm

5. What is the output of the following lines of code? ______

for(int i=0; i<4; i++)

cout << (i * 3) << " ";

A. 0 1 2 3 4 B. 0 3 6 9

C. 0 3 6 9 12 D. 0 1 2 3 E. 0 0 0 0

Explanation:

6 0
2 years ago
Write a program whose input is two integers and whose output is the two integers swapped. Ex: If the input is: 38 then the outpu
Likurg_2 [28]

Answer:

Following are the program in the C++ Programming Language.

#include <iostream>

using namespace std;

//define function for swapping

void SwapValues(int* userVal1,int* userVal2){  

//set integer variable to store the value

int z = *userVal1;

//interchange their value

*userVal1 = *userVal2;  

//interchange their value

*userVal2 = z;

}

//define main method

int main()

{    

//declare variables

int x,y;

//get input from the user

cin>>x>>y;

//Call the method to swap the values

SwapValues(&x,&y);

//print their values

cout<<x<<" "<<y;

return 0;

}

<u>Output</u>:

3 8

8 3

Explanation:

<u>Following are the description of the program</u>.

  • Firstly, we define required header file and function 'SwapValues()', pass two pointer type integer variables in argument that is 'userVal1' and 'userVal2'.
  • Set integer data type variable 'z' and initialize the value of 'userVal1' in it, then initialize the value of 'userVal2' in 'userVal1' and then initialize the value of 'z' in 'userVal2'.
  • Finally, define the main method in which we set two integer type variables and get input from the user in it then, call and pass those variables and print it.
6 0
3 years ago
Other questions:
  • Match each storyboarding technique with its appropriate description
    9·1 answer
  • There are several vehicles in a parking lot. Some of them are motorcycles
    8·2 answers
  • You may be guilty of plagiarism even if
    13·1 answer
  • I need help, whoever gets it correct will get brainliest
    7·1 answer
  • Describe the steps to change an existing macro in Microsoft office 2016
    6·1 answer
  • PLZZZZZZZZZZZZZZZ HELP ME OUT!!!!! I SICK AND TIRED OF PEOPLE SKIPING MYQUESTION WHICH IS DUE TODAY!!!!
    14·1 answer
  • What is connectivity?
    15·2 answers
  • ! (( i &gt; ( f + 1)) es verdadero o falso segun la logica de programación.
    14·1 answer
  • Firewalls are available as a special hardware device or as software. A firewall will block packets of information that are from
    7·1 answer
  • Which are ways that technology keeps you hooked?
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!