Problem Statement
A description of the problem can be found on Hackerrank.
Solution
Check if city
starts with one of ('a'
, 'i'
, 'e'
, 'o'
, 'u'
) and orders them alphabetically.
I created solution in:
All solutions are also available on my GitHub.
SQL
1 2 3 4 |
select distinct city from station where lower(substr(city, 1, 1)) in ('a', 'e', 'i', 'o', 'u') order by city asc; |