Skip to content

Instantly share code, notes, and snippets.

@C-Pro
Last active May 13, 2020 06:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save C-Pro/469c47611ea591859a5f3065035e0f69 to your computer and use it in GitHub Desktop.
Save C-Pro/469c47611ea591859a5f3065035e0f69 to your computer and use it in GitHub Desktop.

Your task is to build one page web application. It will allow user to see length (in days) of continuous periods of sunshine in a given city:

  • Historical longest period of sunny days in given city
  • Longest period in current month
  • Length of current period of sunshine

Length of sunny days period is a number of consecutive days in a given city when the sun is shining (no overcast clouds, no precipitation).

User can select city from dropdown list and frontend should request for data from backend without reloading the page (e.g. REST or smth. similar). Request should be processed in less then 30ms (our service will be very popular!). City selected by user should be preselected next time user visits the page. Data should be stored in database of your choice on the backend. If you wish to showcase your DB prowess - do not use ORM. Initial data loading (e.g. for a year and for 3 cities) should be done in a reproducible manner (e.g. with a script). Continuous periodical update of weather info will be a huge bonus! Data can be obtained via publicly available APIs like http://openweathermap.org/

We would prefer a result to be presented as a github repository without mentions of test task or company name (so you would not spoil all the fun for future candidates by making your code easily googleable).

We will score submissions based on code quality, employed methods and technologies. Comments, tests and other best practices will be highly appreciated as well.

Good luck!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment