Hi guys,
I've been thinking how to solve this problem the whole day.
Problem description
Let's suppose you have a matrix composed of 1's and 0's.(*)
Write a function that recognises if there is at least a 1 that is not adjacent to another 1.
I don't want you to solve the problem, i'd like if you could show me the direction though.
Thought of everithing in my head but it all seems too messy and this is an exercise about C++ Fundamentals, so it shouldn't be so complicated...
Any hint?
(*) ( Is it right to abbreviate ones and zeros like that in your language? ).
I've been thinking how to solve this problem the whole day.
Problem description
Let's suppose you have a matrix composed of 1's and 0's.(*)
Write a function that recognises if there is at least a 1 that is not adjacent to another 1.
I don't want you to solve the problem, i'd like if you could show me the direction though.
Thought of everithing in my head but it all seems too messy and this is an exercise about C++ Fundamentals, so it shouldn't be so complicated...
Any hint?
(*) ( Is it right to abbreviate ones and zeros like that in your language? ).