def furthest_apart_in_state(directorypath, state): """ given the directory where to find entity and region information and a state, return a tuple of the two entity IDs in that state that are furthest apart. If there is only one entity in the state, return None. If there are no entities in the state, return None. :param directorypath: :param state: :return: tuple of two entity IDs """ pass FILE LOOKS LIKE THIS: ID,City,State,Latitude,Longitude A45419E,Plattsburgh,NY,44.704021,-73.471148 A19312D,Aiken,SC,33.554433,-81.69588 A90172S,Tuscaloosa,AL,33.170238,-87.616169 A19394D,Alexandria,VA,38.819853,-77.059645 A27218D,Pittsburgh,PA,40.47441,-79.950968 A68626D,Meadville,PA,41.611599,-80.114891 A17494D,Allentown,PA,40.602658,-75.469236 A86034S,Tonawanda,NY,42.99704,-78.878659 A45142D,Asheville,NC,35.602711,-82.567281 A38298S,Atlanta,GA,33.844371,-84.47405 A14497Y,Roswell,GA,34.055198,-84.370475 A25954D,Austin,TX,30.326374,-97.771258 B46374X,Fairhope,AL,30.480713,-87.861306 B52199S,Cedar Park,TX,30.503949,-97.8242 B83854R,Abingdon,MD,39.472579,-76.277279 B61771D,Blacksburg,VA,37.256283,-80.43473 B84417D,Boerne,TX,29.893137,-98.685719 B71687D,Brevard,NC,35.174351,-82.753971 C77186D,Camden,SC,34.313477,-80.612489 C34069Y,Aldie,VA,38.957718,-77.60375 C27257X,Carrollton,TX,32.962473,-96.89817 C47372X,Columbia,MD,39.206132,-76.887905 H37576E,Cockeysville,MD,39.47931,-76.62996 H51432D,Huntsville,AL,34.718428,-86.556439 A19744F,Albuquerque,NM,35.199592,-106.644831

Computer Networking: A Top-Down Approach (7th Edition)
7th Edition
ISBN:9780133594140
Author:James Kurose, Keith Ross
Publisher:James Kurose, Keith Ross
Chapter1: Computer Networks And The Internet
Section: Chapter Questions
Problem R1RQ: What is the difference between a host and an end system? List several different types of end...
icon
Related questions
Question

def furthest_apart_in_state(directorypath, state):
"""
given the directory where to find entity and region information and a state,
return a tuple of the two entity IDs in that state that are furthest apart.
If there is only one entity in the state, return None.
If there are no entities in the state, return None.
:param directorypath:
:param state:
:return: tuple of two entity IDs
"""
pass
FILE LOOKS LIKE THIS:

ID,City,State,Latitude,Longitude
A45419E,Plattsburgh,NY,44.704021,-73.471148
A19312D,Aiken,SC,33.554433,-81.69588
A90172S,Tuscaloosa,AL,33.170238,-87.616169
A19394D,Alexandria,VA,38.819853,-77.059645
A27218D,Pittsburgh,PA,40.47441,-79.950968
A68626D,Meadville,PA,41.611599,-80.114891
A17494D,Allentown,PA,40.602658,-75.469236
A86034S,Tonawanda,NY,42.99704,-78.878659
A45142D,Asheville,NC,35.602711,-82.567281
A38298S,Atlanta,GA,33.844371,-84.47405
A14497Y,Roswell,GA,34.055198,-84.370475
A25954D,Austin,TX,30.326374,-97.771258
B46374X,Fairhope,AL,30.480713,-87.861306
B52199S,Cedar Park,TX,30.503949,-97.8242
B83854R,Abingdon,MD,39.472579,-76.277279
B61771D,Blacksburg,VA,37.256283,-80.43473
B84417D,Boerne,TX,29.893137,-98.685719
B71687D,Brevard,NC,35.174351,-82.753971
C77186D,Camden,SC,34.313477,-80.612489
C34069Y,Aldie,VA,38.957718,-77.60375
C27257X,Carrollton,TX,32.962473,-96.89817
C47372X,Columbia,MD,39.206132,-76.887905
H37576E,Cockeysville,MD,39.47931,-76.62996
H51432D,Huntsville,AL,34.718428,-86.556439
A19744F,Albuquerque,NM,35.199592,-106.644831

def furthest_apart_in_state(directorypath, state):
given the directory where to find entity and region information and a state||
return a tuple of the two entity IDs in that state that are furthest apart.
If there is only one entity in the state, return None.
If there are no entities in the state, return None.
:param directorypath:
:param state:
:return: tuple of two entity IDs
pass
Transcribed Image Text:def furthest_apart_in_state(directorypath, state): given the directory where to find entity and region information and a state|| return a tuple of the two entity IDs in that state that are furthest apart. If there is only one entity in the state, return None. If there are no entities in the state, return None. :param directorypath: :param state: :return: tuple of two entity IDs pass
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 2 steps with 1 images

Blurred answer
Recommended textbooks for you
Computer Networking: A Top-Down Approach (7th Edi…
Computer Networking: A Top-Down Approach (7th Edi…
Computer Engineering
ISBN:
9780133594140
Author:
James Kurose, Keith Ross
Publisher:
PEARSON
Computer Organization and Design MIPS Edition, Fi…
Computer Organization and Design MIPS Edition, Fi…
Computer Engineering
ISBN:
9780124077263
Author:
David A. Patterson, John L. Hennessy
Publisher:
Elsevier Science
Network+ Guide to Networks (MindTap Course List)
Network+ Guide to Networks (MindTap Course List)
Computer Engineering
ISBN:
9781337569330
Author:
Jill West, Tamara Dean, Jean Andrews
Publisher:
Cengage Learning
Concepts of Database Management
Concepts of Database Management
Computer Engineering
ISBN:
9781337093422
Author:
Joy L. Starks, Philip J. Pratt, Mary Z. Last
Publisher:
Cengage Learning
Prelude to Programming
Prelude to Programming
Computer Engineering
ISBN:
9780133750423
Author:
VENIT, Stewart
Publisher:
Pearson Education
Sc Business Data Communications and Networking, T…
Sc Business Data Communications and Networking, T…
Computer Engineering
ISBN:
9781119368830
Author:
FITZGERALD
Publisher:
WILEY