The map above shows some of the biggest towns (cities) in the state of Maryland . Altogether there are 156 different towns in Maryland . Assuming there used to be absolutely no path connecting two random towns. People want to build one-way paths connecting the towns on condition that if there is a path from Annapolis to Baltimore and this path continues from Baltimore to Columbia then there is no other path from Annapolis to Columbia without passing Baltimore . Find the maximum number of possible paths, considering that any path can start at any town.
This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try
refreshing the page, (b) enabling javascript if it is disabled on your browser and,
finally, (c)
loading the
non-javascript version of this page
. We're sorry about the hassle.
Assuming Annapolis be the town with the most paths (including paths starting from and paths leading to it). We divide the remaining towns into three group:
Group I represents the towns whose paths start from Annapolis
Group I I represents the towns whose paths lead to Annapolis
Group I I I represents the towns whose paths don't start from or leads to Annapolis
Let m = ∣ I ∣ , n = ∣ I I ∣ , p = ∣ I I I ∣ . We have: m + n + p = 1 5 5
We can imply there is no path within the towns of Group I , as well as Group I I
Because Annapolis is the town with the most paths (including paths starting from and paths leading to it) so m + n > m + p and m + n > n + p
= > the number of possible paths maximise when the towns in Group I I I connect with the towns in Group I and I I
The number of paths related with towns in Group I I I doesn't exceed p . ( m + n ) (Because we have assumed that Annapolis is the town with the most paths including paths starting from and paths leading to it ( m + n ) )
The number of possible paths include:
Paths starting from or leading to Annapolis : m + n
Paths related with towns in Group I I I ≤ p . ( m + n )
Paths between Group I and I I ≤ m . n
Therefore m + n + p . ( m + n ) + m . n = m . n + m . ( p + 1 ) + n . ( p + 1 ) ≤ 3 ( m + n + p + 1 ) 2 = 3 ( 1 5 6 ) 2 = 8 1 1 2 a.k.a maximum number of possible paths. This happens when there are 52 towns in each group and towns in Group I have paths to towns in Group I I , towns in Group I I have paths to towns in Group I I I and towns in Group I I I have paths to towns in Group I