Click here to Skip to main content
15,884,298 members
Please Sign up or sign in to vote.
1.00/5 (2 votes)
See more: (untagged)
There will be several continents on a world map. Idea is to identify the number of continents and the mass in each.

The land is denoted by '#' and ocean by spaces. You have to find the number of continents (connected masses of land) and print the number of # in the continent.

Connected mass of land means that # can be connected in any way i.e. horizontally, vertically or diagonally.

What I have tried:

nothing .we need to use c gcc compiler, and need not use processs.h and shouldnt use conio.h
Posted
Updated 29-Jul-16 4:02am

1 solution

"What I have tried:

nothing .we need to use c gcc compiler, and need not use processs.h and shouldnt use conio.h"

Then I'd suggest that it's time you did do something.
We do not do your homework: it is set for a reason. It is there so that you think about what you have been told, and try to understand it. It is also there so that your tutor can identify areas where you are weak, and focus more attention on remedial action.

Try it yourself, you may find it is not as difficult as you think!

If you meet a specific problem, then please ask about that and we will do our best to help. But we aren't going to do it all for you!
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900