First 3*3*3 gives 27
thn modulus operator gives remainder of 27%4
Hence ans is 3..

I got your doubt

U thinking

3*3*3%4
= 3*3*(3%4)
= 3*3*3
= 27

but its wrong ..

U need to refer operator precedence in C

* / % Multiplication/division/modulus left-to-right
so first multiplication is done and thn division if any and thn modulus operator comes..
Hence the result 3..

ya i agree with Shankye
As u already know that modulus operator gives the remainder of the division of two operands ...!!...n in case two operands are such that
x<y then result is x
let's proove this thing
u might have notinced this that the modulus operator gives same result for the operation (x%y) if x is such that, x=a+ny
n=0,1,2,3,4....
thus for this equation to be true...!!
x%y=x for x<y
HOPE THIS HELPS U

Need some help with this Array. I am trying to get the sum of the even numbers and the sum of the odd numbers using a for each loop. I know the answers to what I am trying to achive are sum of even = 84 and the sum of ...

When I execute this progammatically, I get a table with row heights much larger than when I do this manually.

Note : Sel is the Word.Selection object and the Clipboard contains an Excel Table.

public void AddClipboard()
{
Sel.PasteExcelTable(false,false, false);
var t = Sel.Tables[Sel.Tables.Count];
t.AutoFitBehavior(Word.WdAutoFitBehavior.wdAutoFitContent);
}

I have a 2d matrix with dimension (3, n) called A, I want to calculate the normalization and cross product of two arrays (b,z) (see the code please) for each column (for the first column, then the second one and so on).
the function that I created to find the ...