Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

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.

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 Structure

The 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