Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/abdo-essam/cityfinder
A basic city finder app. The user can search for cities and clicking on a city opens Google Maps and navigates to that city's location.
https://github.com/abdo-essam/cityfinder
google-maps gson mvvm-architecture search-algorithm trie-data-structure
Last synced: 3 days ago
JSON representation
A basic city finder app. The user can search for cities and clicking on a city opens Google Maps and navigates to that city's location.
- Host: GitHub
- URL: https://github.com/abdo-essam/cityfinder
- Owner: abdo-essam
- Created: 2024-08-07T00:41:50.000Z (6 months ago)
- Default Branch: master
- Last Pushed: 2024-08-08T19:53:38.000Z (6 months ago)
- Last Synced: 2024-11-21T12:29:25.705Z (2 months ago)
- Topics: google-maps, gson, mvvm-architecture, search-algorithm, trie-data-structure
- Language: Kotlin
- Homepage:
- Size: 4.84 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# City Finder
City Finder is an Android application that allows users to search for cities and view their locations on Google Maps. This project is designed to evaluate problem-solving skills, UX judgment, and code quality.
## Features
- Load a list of cities from a JSON file.
- Filter results by a given prefix string.
- Display cities in a scrollable list, in alphabetical order.
- Show city and country code as the title.
- Show coordinates as a subtitle.
- Show the location of the city on Google Maps when tapped.## Data Structure and Search Algorithm
### Trie Data StructureThe Trie (prefix tree) data structure is used to optimize the search functionality. This allows for efficient prefix-based searches, making the application responsive even with a large dataset of cities.
Why Trie?
- Efficient Searches: The search time complexity is O(m), where m is the length of the search prefix.
- Memory Usage: The Trie is space-efficient as common prefixes are stored once.## Screenshots