HackerRank/SQL

[hackerrank] Weather Observation Station 20

예쁜꽃이피었으면 2022. 8. 22. 13:45

[hackerrank] Prepare > SQL > Aggregation > Weather Observation Station 20

 

[문제]

 

A median is defined as a number separating the higher half of a data set from the lower half. Query the median of the Northern Latitudes (LAT_N) from STATION and round your answer to  decimal places.

Input Format

The STATION table is described as follows:

where LAT_N is the northern latitude and LONG_W is the western longitude.

[MYSQL]

 

 

[ORCALE]

select round(median(lat_n),4)
from station;

 

 

 

반응형