[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

Re: Maths in Ruby

Yannick Grams

3/5/2007 9:10:00 AM

Absolutely certain. Unless of course this is a trick question. WHich I
doubt. But thanks for everyone's help!

>From: "M. Edward (Ed) Borasky" <znmeb@cesmail.net>
>Reply-To: ruby-talk@ruby-lang.org
>To: ruby-talk@ruby-lang.org (ruby-talk ML)
>Subject: Re: Maths in Ruby
>Date: Mon, 5 Mar 2007 18:08:59 +0900
>
>Yannick Grams wrote:
>>Hello to everyone!
>>
>>I have a mathematic problem I need to solve, and it involves finding the
>>values of three consecutive numbers, x, y and z. I need to be able to find
>>every instance of these from negative one million (-1,000,000) up to one
>>million (1,000,000). They must follow the following equations:
>>
>>x + y + z = 5
>>x + y - z = 7
>>(x - y)(x - y)(x - y) + (y - z)(y - z)(y - z) = (x - z)(x - z)(x - z)
>>
>>I'm completely and utterly stumped. I intend on solving this via Ruby, as
>>doing it on pen and paper might take a while. ;) If anyone has any
>>suggestions, I'd love to hear them.
>Well, one of the reasons you might be stumped is that the problem as posed
>does not appear to have a solution. I punched it in to Maxima:
>
>(%o1) z+y+x=5
>(%o2) -z+y+x=7
>(%o4) (y-z)^3+(x-y)^3=(x-z)^3
>(%i5) solve([%o1,%o2,%o4], [x,y,z]);
>(%o5) [[x=-1,y=7,z=-1],[x=3,y=3,z=-1],[x=7,y=-1,z=-1]]
>
>Since one of the equations is a cubic, there are three solutions, and they
>are all smallish integers. But they are *not* consecutive!
>
>Are you sure about the problem statement?
>
>
>--
>M. Edward (Ed) Borasky, FBG, AB, PTA, PGS, MS, MNLP, NST, ACMC(P)
>http://borasky-research.blo...
>
>If God had meant for carrots to be eaten cooked, He would have given
>rabbits fire.
>
>

_________________________________________________________________
Advertisement: Amazing holiday rentals?
http://a.ninemsn.com.au/b.aspx?URL=http%3A%2F%2Fwww%2Eninemsn%2Erealestate%2Ecom%2Eau%2Fcgi%2Dbin%2Frsearch%3Fa%3Dbhp%26t%3Dhol%26cu%3DMSN&_t=758874163&_r=HM_Txt_Link_Holiday_Oct06&...


3 Answers

Dano

7/2/2012 5:23:00 AM

0

"William December Starr" wrote in message
news:jsqn1v$k84$1@panix2.panix.com...

In article <jsq5p4$gla$4@news.albasani.net>,
"Adam H. Kerman" <ahk@chinet.com> said:

> Barb May <barbmay@nonofyourbusinessx.tv> wrote:
>>I rish Mike wrote:
>>
>>> In addition, there is the death of US Border Guard Brian Terry
>>> who was killed, on American soil, with guns from Fast and
>>> Furious.
>>
>> Mike repeats another lie. F&F guns were found at the scene, but
>> they were not proven to be the weapons that killed Terry.
>
> "Barb May" commits an error of ommission in "her" correction, so
> "she" can go fuck "herself". It was impossible to perform
> forensics on the bullet fragments recovered, so the weapons
> recovered at the crime scene known to be part of F&F couldn't be
> ruled out either.

Wow. You're being even more assholy than usual here.


=====================================

Is that even possible?

inngenue

7/2/2012 5:58:00 AM

0

On 02/07/2012 1:22 AM, Dano wrote:
> "William December Starr" wrote in message
> news:jsqn1v$k84$1@panix2.panix.com...
>
> Wow. You're being even more assholy than usual here.
>
> =====================================
>
> Is that even possible?

How ironic.

--
Including creationism in science curriculum is like including study of
the tooth fairy in dental school.

HydraBlanky

7/2/2012 6:46:00 AM

0

"Adam H. Kerman" <ahk@chinet.com> blew the cruet over ATTRIB:
>William December Starr <wdstarr@panix.com> wrote:
>>"Adam H. Kerman" <ahk@chinet.com> said:
>>>>ahk@chinet.com wrote:
>>>>>barbmay@nonofyourbusinessx.tv wrote:
>>>>>>Mike repeats another lie. F&F guns were found at the scene, but
>>>>>>they were not proven to be the weapons that killed Terry.
>
>>>>>"Barb May" commits an error of ommission in "her" correction, so
>>>>>"she" can go fuck "herself". It was impossible to perform
>>>>>forensics on the bullet fragments recovered, so the weapons
>>>>>recovered at the crime scene known to be part of F&F couldn't be
>>>>>ruled out either.
>
>>>>Wow. You're being even more assholy than usual here.
>
>>>If you can't see the hypocrisy in that "correction", you're an
>>>idiot.
>
>>If you get to define what reality is, then yes, you're right.
>>Otherwise, not so much.
>
>>I will admit, your technique make it impossible to force you to
>>concede that you're wrong about anything.
>
>I'm not wrong. "Barb May" left important details out in "her" attempt
>to "correct" Irish Mike. She was being deliberately misleading, which
>made it an error of omission and thus a lie, you know, what she accused
>Irish Mike of committing.
>
well, Adam...it IS a twoll - sheeesh!
settle down before you blow an artery...FFS : p

>You got it wrong.
>
so?
the guy is using a boxed up usenet package.
****Organization: PANIX Public Access Internet and UNIX, NYC
maybe the site got it wrong?

>Nice bit retaining quotes but snipping attributes. Don't do that,
>especially if you're attempting to issue a "correction".
>
sometimes i do wonder just what motivates you Adam - among
your peers - to throw around your weight with such lame snipes.
The "Sheik of the Usenetz" mirage, spread from alt.config, no less.

YANBT...i have thought the same as you are thinking however the
weight of evidence does not add up, so far.

yes, "wds" is quick to feed Derbyshlre trolling:
Message-ID: <igqpef$ft$1@panix1.panix.com>
Message-ID: <igjhek$r2c$1@panix2.panix.com>

yes, same TZ and a lot of style similarities.

but equally so "wds" leaps to with comments on the nutty posts from
the sciFi groups giving head to the fantasy types like:
http://al.howardknight.net/msgid.cgi?ID=13...

add to all the fact "wds" predates Derbyshlre in (paid) subscribed
posts and I reckon you can rest easy. "wds" is just another of the
chain tuggers long established around the usenet. and he knows about linux!
nobody can throw the first stone in that case eh?
++++++From: wdstarr@panix.com (William December Starr)
++++++Newsgroups: rec.arts.sf.written
++++++Subject: Re: Discussing the 2004 Hugo Nominees for Novel
++++++Date: 22 Apr 2004 04:12:48 -0400
++++++Organization: PANIX Public Access Internet and UNIX, NYC
++++++Message-ID: <c67uq0$o90$1@panix2.panix.com>
++++++
++++++If anyone was wondering what name the real-world Yugo has in Neal
++++++Stephenson's _Cryptonomicon_ universe, where IBM is ETC (Electronic
++++++Tally Corporation) and Linux is Finux, I think now we know... :-)

you see Adam, unlike you i build my paranoia from the hand of the people who
post it. I do not guess, I find and link to it. you might try doing that work and
your head will rest a way lot easier?

now, on your way, Sheik <snorts>