Computer Science, asked by adityalakhani09, 2 months ago

x=0
if x<4:
X=X+1
print("x is ", x)
what will be the output in python language ​

Answers

Answered by anindyaadhikari13
2

Required Answer:-

Given Cσde:

x=0

if x<4:

     x=x+1

print("x is ",x)

To Find:

  • The output of the given cσde snippet. (Language: Python)

Output:

>> x is 1.

Explanation:

  • Initially, x = 0. Now, x < 4 is true as 0 < 4 is true.
  • So, value of x is incremented by 1.
  • x becomes 1.
  • So,output: x is 1.

Refer to the attachment.

•••♪

Attachments:
Answered by gohiljayrajsinh1111
0

Answer:

x is 1 is The Answer for This

Similar questions