1.

Given here is an algorithm to swap two numbers. Which of the following line will replace "?" to complete the algorithm?Step 1: Read two numbers X and Y.Step 2: ?Step 3: Y = X - YStep 4: X = X - Y 

A. \[X=X+Y\]
B. \[X=X\times Y\]
C. \[X=X/Y\]
D. \[X=X-Y\]
Answer» B. \[X=X\times Y\]


Discussion

No Comment Found

Related MCQs