Microsoft Interview Question

Q. Cycle detection in weighted graphs