From owner-freebsd-questions@FreeBSD.ORG Tue Oct 23 04:34:49 2012 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id B1ADA453 for ; Tue, 23 Oct 2012 04:34:49 +0000 (UTC) (envelope-from erichfreebsdlist@ovitrap.com) Received: from alogreentechnologies.com (alogreentechnologies.com [67.212.224.110]) by mx1.freebsd.org (Postfix) with ESMTP id 5E21A8FC0A for ; Tue, 23 Oct 2012 04:34:49 +0000 (UTC) Received: from X220.ovitrap.com ([122.129.201.2]) (authenticated bits=0) by alogreentechnologies.com (8.13.1/8.13.1) with ESMTP id q9N4YauB010779; Mon, 22 Oct 2012 22:34:40 -0600 Date: Tue, 23 Oct 2012 11:34:36 +0700 From: Erich Dollansky To: Gary Kline Subject: Re: way way off topic Message-ID: <20121023113436.6748c811@X220.ovitrap.com> In-Reply-To: <20121023042007.GA14738@ethic.thought.org> References: <20121023042007.GA14738@ethic.thought.org> X-Mailer: Claws Mail 3.8.0 (GTK+ 2.24.6; amd64-portbld-freebsd10.0) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: FreeBSD Mailing List X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 23 Oct 2012 04:34:49 -0000 Hi, On Mon, 22 Oct 2012 21:20:07 -0700 Gary Kline wrote: > > apologies up front for this math type quandary. I had it in a std C > program, but 3+ hours of grepping havent found it. I would have bet > my last cent that I had a summary Somewhere, but cant find that > either. > > here is the problem as best I can remember it. > > > let's say that john is 8 and his older friend, jim, is 22. > how much older is exact percentage terms is jim? > > to find the answer I had to find the relative difference {22 - 8} and > then do something with the difference. this isn't any kind of trick > or "advanced-cognition"; I just thought it was clever [and exact]. > it obviously works for finding the abs() results in subtraction. > it's something I found on the web and swipes and save the prose > discussion. BZZT: Lost, :-( > It seems that I am also lost. What should abs() do here? I would multiply the age of john and the difference with 100 and then divide the result to get the percentage. Or did I get lost here? > if this seems dumb, I plead guilty! > > im asking here because -questions is the sharpest list on the net. > Are you sure? Erich