Which Python script correctly implements the logic for mapping (latitude, longitude) positions to quadrants of the earth? Assume latitude and longitude are within the given ranges.
-180 <= longitude < 0
0 <= longitude <= 180
-90 <= latitude < 0
South Western Quadrant (SW)
South Eastern Quadrant (SE)
0 <= latitude <= 90
North Western Quadrant (NW)
North Eastern Quadrant (NE)
Select one:
sum = latitude + longitude
if sum == 0:
quadrant = NW
elif sum < -90:
quadrant = SW
elif sum > 90:
quadrant = NE
else:
quadrant = SE
None of the answers are correct
if latitude < 0:
if longitude <= 0:
quadrant = SW
else:
quadrant = SE
elif longitude <= 0:
quadrant = NW
else:
quadrant = NE
More than one of the answers is correct
if latitude < 0:
if longitude > 0:
quadrant = SW
else:
quadrant = SE
else:
if longitude > 0:
quadrant = NW
else:
quadrant = NE
if latitude < 0:
ns = "S"
else:
ns = "N"
if longitude < 0:
ew = "W"
else:
ew = "E"
quadrant = ns + ew