Gate CS-2006 Question Paper With Solutions

Q. 11 A set X can be represented by an array x[n] as follows

Gate CS-2006 Question Paper With Solutions

Consider the following algorithm in which x,y and z are boolean arrays of size n;

algorithm zzz(x[], y[], z[]) {
    int i;
    
    for(i=; i<n; ++i)
        z[i] = (x[i]  ~y[i])  (~x[i]  y[i]);
}

The set Z computed by the algorithm is Gate CS-2006 Question Paper With Solutions Answer: (D)

Explanation: Gate CS-2006 Question Paper With Solutions

Learn More:   Gate CS-2004 Question Paper With Solutions

LEAVE A REPLY

Please enter your comment!
Please enter your name here