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

A 1.8-kg object moves in the x direction according to the following function: x(t) = 2t2 + 3t − 5 (SI units). What is the force on the object after 2.7 s?
Can some one please help me ?
Why was the Monroe Doctrine important for the United States ?
"Do you know the name of the most famous peanut farmer in Georgia?" Is this sentence a Imperative, Exclamatory, Declarative, Interrogative?
Which of the following is true of an electrolytic cell?  a. An electric current causes an otherwise non-spontaneous chemical reaction to occur.  b. Reduction o
What are the tiny particles that makes up all matter around us?
Explain how you can use multiplication to find the perimeter of a square
What does human characteristics mean?
Points A,B,C,D, and E are collinear and in that order. Find AC if AE = x+50 and CE = x+32.
Find the value of the variables (x + 10) (4x - 35)