## Adobe Interview Question for Testing / Quality Assurances

Country: United States
Interview Type: Phone Interview

Comment hidden because of low score. Click to expand.
7
of 7 vote

nice question, just came to know that on comparison of unsigned and signed, signed is converted to unsigned. so answer will be "Y is greater"

Comment hidden because of low score. Click to expand.
0

What is the value of y after being converted into unsigned ?

Comment hidden because of low score. Click to expand.
0

The first bit of Y which was previously being used to represent its sign will now be used to represent just its value (just for comparison). Y actually does not change. The value of Y during comparison with X is 4294967294.

Comment hidden because of low score. Click to expand.
0

Comment hidden because of low score. Click to expand.
0
of 0 vote

can u please tell me how to see the value of Y during the comparison?

Comment hidden because of low score. Click to expand.
0
of 0 vote

value of Y is computed as follows --

on a compiler which sees int as 4 bytes ...

Y = 2^32 - |original value of y|

Comment hidden because of low score. Click to expand.
0
of 0 vote

The value of y which is stored in computer (-2) is as follows
(binary form and assuming 32 bits ) : 11111111 11111111 11111111 11111110 . Now this binary representation is for Signed numbers . If it is converted to unsigned , then nothing changes . Simply convert this binary number to decimal INCLUDING the most significant bit i.e the 32nd bit . Hence the decimal number will be 2^(0) + 2^(1)+2^(2)+.......2^(31)=4294967294

Hope this helps :D

Comment hidden because of low score. Click to expand.
-2
of 2 vote

what is pf?

Comment hidden because of low score. Click to expand.
0

obviously printf

Name:

Writing Code? Surround your code with {{{ and }}} to preserve whitespace.

### Books

is a comprehensive book on getting a job at a top tech company, while focuses on dev interviews and does this for PMs.

### Videos

CareerCup's interview videos give you a real-life look at technical interviews. In these unscripted videos, watch how other candidates handle tough questions and how the interviewer thinks about their performance.