The % operator is used to return the remainder if one number were to be divided by another. So 5 % 2 would return 1, because 2 goes into 5 twice, with 1 left over. Another example is 10 % 2 which would return 2. 4 goes in twice, with 2 left over.
So x % n == 0 just means that there is no remainder (it fits perfectly).
Hope that helped!
Oh, ok. The reason why I stick with 2.5 is because of WConio, and I haven't been able to find out how to get it to work with 2.6 yet. I'd need to modify the .pyd file for it, but I have no idea how to do that (the file looks like gibberish to me when I open it in Windows). http://newcenturycomputers.net/projects/wconio.html
Write a C program that should create a 10 element array of random integers (0 to 9). The program should total all of the numbers in the odd positions of the array and compare them with the total of the numbers in the even positions of the array and indicate ...
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 ...