1. Computer problem? Tech Support Guy is completely free -- paid for by advertisers and donations. Click here to join today! If you're new to Tech Support Guy, we highly recommend that you visit our Guide for New Members.

forumla for difference

Discussion in 'Business Applications' started by roebkk, Oct 26, 2007.

Thread Status:
Not open for further replies.
Advertisement
  1. roebkk

    roebkk Thread Starter

    Joined:
    Oct 26, 2007
    Messages:
    3
    I have two columns with times in each in seconds. I need a formula for the difference between the two columns, which is easy. The part that gets me is that sometimes the first column is the higher number and sometimes the 2nd column is the higher number. I do not want negatives to show up, simply the difference in seconds between the columns regardless of which column has a higher time. (These are two races and I am looking for the most consistant runner with the closest time.)
     
  2. Zack Barresse

    Zack Barresse

    Joined:
    Jul 25, 2004
    Messages:
    5,452
    Hi there, welcome to the board!

    How about ...

    =Max(A1:B1)-Min(A1:B1)

    ??
     
  3. roebkk

    roebkk Thread Starter

    Joined:
    Oct 26, 2007
    Messages:
    3
    Thanks but it ends up always answering 0?
     
  4. Zack Barresse

    Zack Barresse

    Joined:
    Jul 25, 2004
    Messages:
    5,452
    It's not zero, it's a fraction of an integer. Dates and times are different in Excel. One complete day (24 hours) is 1 whole number. So 12 hours will be 0.5 as a numerical value. You just need to either show more decimal places or format as time. :)
     
  5. roebkk

    roebkk Thread Starter

    Joined:
    Oct 26, 2007
    Messages:
    3
    Oops! I forgot to update the cell address when I copied/pasted. I think this will work! Thanks.
     
  6. slurpee55

    slurpee55

    Joined:
    Oct 20, 2004
    Messages:
    7,837
    Zack, wouldn't =ABS(A1-B1) work just as well?
     
  7. Zack Barresse

    Zack Barresse

    Joined:
    Jul 25, 2004
    Messages:
    5,452
    Yes, yes it would. :)
     
  8. Sponsor

As Seen On
As Seen On...

Welcome to Tech Support Guy!

Are you looking for the solution to your computer problem? Join our site today to ask your question. This site is completely free -- paid for by advertisers and donations.

If you're not already familiar with forums, watch our Welcome Guide to get started.

Join over 733,556 other people just like you!

Thread Status:
Not open for further replies.

Short URL to this thread: https://techguy.org/643986

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice