Matlab matrix indexing

broken image

I have to provide a working code in octave of this problem by tommorow. I have achieved to solve it using loops, for loops to be specific, but my teacher is forcing to solve this problem using indexing, whatever that means, or i risk getting bad grade. So, first of all, i need to check if a student, or given line first number is more >= 8.5 AND second number is = 0, secondly, if these conditions are met, i need to store this line in a new array. If second number is 0, they are eligible, if it is 1, they are not.Īn example of my list would be like this:Īdditional thing is that, to be eligible for scholarship, not only second number has to be 0, but The first number represents student average grade, the second number represents if a student is eligible for a scholarship. In the list there is 2 numbers for each students.

broken image
broken image
broken image

The Problem - I have a list of n students. I have a problem regarding arrays or matrices, in that i need to check two numbers at the same time for condition.

broken image