So basically I have 2 arrays, int A[6][8] and bool B[6][8].
What I need to do is to read from a file 48 numbers and put them in the array. Till there everything is fine.
After that I should assing bool valuables to the elements of B so that for every i in[0...5] and j in [0...7] B[i][j]=true if and only if every component of the row A[i] can be found in the column A[][j].
Then save the bool valuables of B into a file called output.
I basically got stuck at the bool part. Here is my code. I need to use while and if to solve it, and not do-while or for.. It might be really easy, but for me it's not !
Why is line 45 if(l>=5)? Shouldn't it be if (l > 5) or if (l == 6)?
Also, you're missing a j = 0; somewhere between lines 40 and 56.
Lines 47 and 51 should use B[p][t] and not B[i][j].
For the loop beginning line 71, why are you just outputting a bunch of 1's? That doesn't tell you anything without the 0's too. You might want to add some line breaks too, so you end up with a 6x8 rectangle instead of a 48 long line. You also forgot to increment i and j at the end of those loops.