Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!xlned.com!feeder1.xlned.com!newsfeed.xs4all.nl!newsfeed3.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.100 X-Spam-Evidence: '*H*': 0.80; '*S*': 0.00; '22,': 0.09; 'computed': 0.09; 'assume': 0.14; 'pulling': 0.16; 'width,': 0.16; 'wrote:': 0.18; 'seems': 0.21; 'mon,': 0.24; 'header:In-Reply-To:1': 0.27; 'point': 0.28; 'points': 0.29; 'message-id:@mail.gmail.com': 0.30; "i'm": 0.30; 'lines': 0.31; "i'd": 0.34; 'problem': 0.35; 'agree': 0.35; 'received:209.85': 0.35; 'problem.': 0.35; 'received:google.com': 0.35; 'received:209': 0.37; 'christian': 0.38; 'to:addr:python-list': 0.38; 'pm,': 0.38; 'to:addr:python.org': 0.39; 'read': 0.60; 'such': 0.63; 'between': 0.67; 'stated': 0.69; 'hull': 0.84; '2013': 0.98 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:mime-version:in-reply-to:references:from:date:message-id :subject:to:content-type; bh=VQBHOGc4zEnJMGWiMiokaqawbztdPKcGO8ZJuJ0Xa+U=; b=Pj3JQfnkLRjAX4kSfpBDNmLJa2YeFJsNVVrYKpnnJgSZpcJ5a+uH0KJvzTUBR0aitz b5zYD0llDH8iM/AFtQ9/gFbBmPXyrUyNKctTyp06JAs7k/m6qh2N1JJy2zMawRwNPHT/ qrTZ9qhMN/QQ8O83Du8mwf28pZpXqGWyzmz2ui9XsN14MmE5n4It4eMSS6V2cktAwloa gOmBoLgaR+/HWABjVqBsxF8HYIV2FIVMsx97hqcO7ACXjK2B5c3WlQsqs270WCT7ax+P IIHm1lSxiFz8mON35aitYXiHsSwNxAF4Y3e/sMGbGoSZDRgcVmd0hNWI9K554qTJpS+t ac6A== X-Received: by 10.68.218.103 with SMTP id pf7mr14006577pbc.153.1366670214859; Mon, 22 Apr 2013 15:36:54 -0700 (PDT) MIME-Version: 1.0 In-Reply-To: References: <09f7da52-b0d6-4167-957f-d207faf33d07@googlegroups.com> From: Ian Kelly Date: Mon, 22 Apr 2013 16:36:14 -0600 Subject: Re: Confusing Algorithm To: Python Content-Type: text/plain; charset=ISO-8859-1 X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 11 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1366671551 news.xs4all.nl 2231 [2001:888:2000:d::a6]:34898 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:44119 On Mon, Apr 22, 2013 at 2:33 PM, Christian Gollwitzer wrote: > I'd agree with your interpretation. "Threads are straight lines and cannot > intersect towers" - I read it such that the answer is the "convex hull" of > the set of points given by the tower height. The convex hull can be computed > for this 1D problem by initializing with > line segments between every point and repeatedly pulling up every > non-convex piece, if I'm not mistaken. I agree that seems the likely intention. One also must assume that the towers are evenly spaced and have point width, neither of which are stated in the problem.