Question: / * * EX: 5 . 5 Elsewhere in the program we have defined two signed 8 - bit integers, X and

/** EX: 5.5
Elsewhere in the program we have defined two signed 8-bit integers,
"X" and "Y".
TASK: Write C code to:
1. Multiply X by Y and store the result in a variable called "alpha".
2. If "alpha" is positive:
perform a bitwise left shift by two positions.
If "alpha" is negative:
perform an arithmetic right shift by four positions.
3. Store the result from step 2 in a variable called "beta".
Upon completion, uncomment the printf() statement below.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!