My orders
How it works
Examples
Reviews
Blog
Homework Answers
Submit
Sign in
How it works
Examples
Reviews
Homework answers
Blog
Contact us
Submit
Fill in the order form to get the price
Subject
Select Subject
Programming & Computer Science
Math
Engineering
Economics
Physics
Other
Category
C++
Software Engineering
Java | JSP | JSF
Databases | SQL | Oracle | MS Access
C
Python
Excel
C#
Visual Basic
Computer Networks
Functional Programming
Android
Assembler
UNIX/Linux Programming
ASP | ASP.NET
MatLAB
Wolfram Mathematica
MathCAD
Maple
Perl
Action Script | Flash | Flex | ColdFusion
Ruby | Ruby on Rails
Prolog
Objective-C | Swift
Algorithms
Web Development
HTML/JavaScript Web Application
NodeJS Web Application
Other
Deadline
Timezone:
Title
*
Task
*
{"ops":[{"insert":"Dynamic Programing - City Planning. A city planner is asked to organize grocery shops in a new city. The city has a straight line main street that goes throughout the city. The city planner is asked to position where should the city provide permits to build new grocery shops so that people of the new city can have the shortest distance to their grocery markets. The population density is not constant along both sides of the main street. A higher density is around multiple city centers or crossroads along side the main street.\nYour task is to develop an algorithm, given the positions of the city centers and the number of grocery shops, computes the least possible sum of all distances between each city centers and its nearest grocery shop.\nInput to your Algorithm:\nList of city centers coordinate positions along the main street (each an integer number"},{"attributes":{"list":"ordered"},"insert":"\n"},{"insert":"between 1 and 1000). This is a sequence of numbers."},{"attributes":{"list":"ordered"},"insert":"\n"},{"insert":"Number of city centers is an integer between 2 and 100."},{"attributes":{"list":"ordered"},"insert":"\n"},{"insert":"Number of grocery shops (an integer number between 2 and 30)."},{"attributes":{"list":"ordered"},"insert":"\n"},{"insert":"The number of shops is smaller than the number of city centers."},{"attributes":{"list":"ordered"},"insert":"\n"},{"insert":"Output of your algorithm: A single integer, which is the sum of all distances between each city center and its nearest grocery market.\nSample Input:\n5\n[1 2 3 6 7 9 11 21 40 50]\nSample Output:\n9\nFigure 1: A visualization of City Center Positions and Grocery Shops. (Numbers in grocery shop row is the distance to the nearest shop. )\n"},{"attributes":{"bold":true},"insert":"Tasks:"},{"insert":"\nTask 2.1. What are the sub-problems in this case? What is the counts of sub-problems? Provide a brief description of your solution."},{"attributes":{"list":"bullet"},"insert":"\n"},{"insert":"Task 2.2. Write up your algorithm in Pseudocode or python implementation."},{"attributes":{"list":"bullet"},"insert":"\n"},{"insert":"Task 2.3. What is the run time complexity of your algorithm?"},{"attributes":{"list":"bullet"},"insert":"\n"},{"insert":"\n\n"}]}
I need basic explanations
Special Requirements
Upload files (if required)
Drop files here to upload
Add files...
Account info
Already have an account?
Create an account
Name
*
E-mail
*
Password
*
The password must be at least 6 characters.
I agree with
terms & conditions
Create account & Place an order
Please fix the following input errors:
dummy