Computers and Technology
Computers and Technology, 07.12.2021 05:40, tati7149

Java Mijid the Great is the king of Dodars territory. He likes to travel between the cities in his territory and actually, you can never see him in the same city as where he was the day before. Therefore, he captured all territories of his continent! In spite of this fact, he has seen all cities of his territory so far and wants to capture another continent in order to have some choices to travel into new cities. Now, having the world map, he needs your help to find the biggest continent except the one in which he resides. Maps are given as M × N tables, filled with at most two different letters denoting land and water regions. A continent is a set of connected land regions which is completely surrounded by water regions or the end of map. Two regions are assumed to be connected if they have an edge in common. The coordinates of top left region is (0,0) and bottom right region (M − 1, N − 1). Region with coordinates (x, N − 1) should be assumed to have a common edge with region (x, 0) for every x between 0 and M − 1 (inclusive). Input There will be several test cases. Each test case contains two integers M ≤ 20 and N ≤ 20 in the first line denoting the number of rows and columns in the map respectively. Next, there will be M lines of exactly N characters representing the map. Finally in the last line there would be two integers 0 ≤ X < M and 0 ≤ Y < N , the coordinates of the region in which Mijid the Great currently stays. There will one blank line after each test case.

Output
For each test case, output a line containing an integer that is the number of regions in the biggest continent that Mijid the Great can capture.

answer
Answers: 2

Other questions on the subject: Computers and Technology

image
Computers and Technology, 21.06.2019 22:00, haydonmetzger
Which one of the following identifies the primary a purpose of information classification processes? a. define the requirements for protecting sensitive data. b. define the requirements for backing up data. c. define the requirements for storing data. d. define the requirements for transmitting data.
Answers: 2
image
Computers and Technology, 22.06.2019 03:00, nsjcbdhcb
Data is processed, stored, and transmitted as a series of 1s and 0s. each 1 or 0 is called a(n) . a series of eight 0s and 1s, called a(n) , represents one character—a letter, number, or punctuation mark. data becomes when it is presented in a format that people can understand and use. digital signals are represented by two different , such as +5 volts and +.2 volts. digital data can also take the form of light and dark spots etched onto the surface of a cd or the positive and negative orientation of particles on the surface of a hard disk. data consists of numbers that might be used in arithmetic operations. it can be represented digitally using the number system. data is composed of letters, symbols, and numerals that are not used in arithmetic operations. computers represent this type of data using , ebcdic, unicode, or utf-8. data is quantified using terms such as or kibibyte (1024 bytes), and prefixes such as or mebi (1,048,576), and giga or (1,073,741,824). to reduce file size and transmission times, digital data can be compressed. compression provides the means to compress data and reconstitute it into its original state. compression throws away some of the original data during the compression process. compressed files usually have at the end of the file name and are represented with special icons. these files have to be or unzipped before you can view the data they contain.
Answers: 1
image
Computers and Technology, 22.06.2019 14:30, chaparro0512
Create a pseudocode design to prompt a student for their student id and the titles of the three classes they want to add. the solution should display the student’s id and a total bill. • bill a student using the following rules: o students can only add up to 3 classes at a time.
Answers: 3
image
Computers and Technology, 23.06.2019 09:00, opgbadwolf5
What provides an array of buttons for quick access to commonly used commands and tools
Answers: 1
Do you know the correct answer?
Java Mijid the Great is the king of Dodars territory. He likes to travel between the cities in his...

Questions in other subjects:

Konu
Mathematics, 24.01.2021 03:00
Konu
Arts, 24.01.2021 03:00
Konu
Mathematics, 24.01.2021 03:00