Ratio problem.

Discussion in 'Perl' started by Raidenji, Dec 1, 2003.

  1. Raidenji

    Raidenji Guest

    i would like to know if its possible and what the formula is for taking two
    numbers a seeing if they equal a certain ratio ?
    Raidenji, Dec 1, 2003
    #1
    1. Advertising

  2. Raidenji

    Nick Santos Guest

    well, if I'm understanding what you want, I'd say take your ratio and turn
    it into a decimal. eg: 1:2 = 1/2 = .5 and then take the two numbers you'd
    like to test (eg: $x and $y) and test whether $x/$y = .5 and/or whether
    $y/$x = .5 depending on what your input is. Not sure if that's what you
    wanted, but hope it helped
    -Nick

    "Raidenji" <> wrote in message
    news:fBxyb.2630$...
    > i would like to know if its possible and what the formula is for taking

    two
    > numbers a seeing if they equal a certain ratio ?
    >
    >
    >
    Nick Santos, Dec 1, 2003
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. =?Utf-8?B?RGF2aWQgV2hpdGNodXJjaC1CZW5uZXR0?=

    Newbie: Image button aspect ratio

    =?Utf-8?B?RGF2aWQgV2hpdGNodXJjaC1CZW5uZXR0?=, Nov 6, 2004, in forum: ASP .Net
    Replies:
    5
    Views:
    1,212
    Scott M.
    Nov 7, 2004
  2. Arthur Hsu
    Replies:
    5
    Views:
    5,926
    Steven Cheng[MSFT]
    Dec 8, 2004
  3. Brian
    Replies:
    1
    Views:
    1,106
    Bruce Barker
    Dec 6, 2005
  4. Bremse

    signal to noise ratio

    Bremse, Feb 2, 2005, in forum: Java
    Replies:
    0
    Views:
    360
    Bremse
    Feb 2, 2005
  5. mharness
    Replies:
    0
    Views:
    430
    mharness
    Sep 28, 2006
Loading...

Share This Page