Advertisement
Guest User

Untitled

a guest
Dec 16th, 2012
52
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
OCaml 0.32 KB | None | 0 0
  1. let string_of_vector (v : vector) =
  2.     let string_of_double (f : float) =
  3.         let s = string_of_float f in
  4.         let l = (String.length s) - 1 in
  5.         if (String.get s l) <> '.' then s else s ^ "0" in
  6.     "<" ^ (String.concat "," [(string_of_double v.x) ; (string_of_double v.y) ; (string_of_double v.z)]) ^ ">"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement