Jhen7241 Jhen7241
  • 14-09-2019
  • Computers and Technology
contestada

If variable x has value 2 and y has value 1, which values could result from the following Jack expression?

x + 3 * 4 - y

Respuesta :

StaceeLichtenstein StaceeLichtenstein
  • 19-09-2019

Answer:

The result of the given expression is 13.

Explanation:

Here x and y are the two variable which has value 2 and 1 respectively.

x+3*4-y

Here  operator *  is more precedence then that + operator so

=2+(3*4)-1

2+12-1 now + operator  is more precedence then that - operator so

=(2+12)-1

=(14-1)

=13

Following are the program in C language

#include <stdio.h>// header file

int main() // main function

{

   int x=2,y=1; // variable declaration

   printf("%d",x+3*4-1); b// final result

return 0;

}

Output:13

Answer Link

Otras preguntas

Recursive equation for -2, -5, -8, -11, -14
What is the quotient when 8465 is divided by 5?
x^3+12x^2+kx+7 is divided by(x+4),the remainder is -9 find k.
Neal prepared 3 meals each day. He prepared 27 meals in all. What equation represents the number of days Neal prepared meals? ( 27 x3 = n 3x n = 27 n = 27 = 3 3
Please help! Very easy! The first two screenshots are the word list of the words that you will use for the 3rd screenshot.
What are the 4 properties of hydrogen bonds?
John has 3 fewer dimes than quarters. He has twice as many nickels as quarters. Altogether he has $6.45, how many of each coin does he have?
There are four consumers willing to pay the following amounts for haircuts, and there are four haircutting businesses with the following costs: Consumers' Willi
What were 3 ways greek dramas are different to Greek tragedies?
Don’t understand this