Don't like ads? PRO users don't see any ads ;-)
Guest

Untitled

By: a guest on Aug 5th, 2012  |  syntax: None  |  size: 0.20 KB  |  hits: 22  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. Distance between two points in xcode [closed]
  2. float a = absolute_value(y1 - y2);
  3. float b = absolute_value(x1 - y2);
  4.  
  5. float dist = square_root(a^2 + b^2);  // dist is the distance between the two points