Quantcast
Channel: Programming Forums
Viewing all articles
Browse latest Browse all 51036

Identifing an isolated character in a matrix

$
0
0
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? ).

Viewing all articles
Browse latest Browse all 51036

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>