Re: [問題] 面試問到的問題...

作者: Leon (Achilles)   2012-12-13 15:48:18
※ 引述《Leon (Achilles)》之銘言:
: : 接著說明一下直線截成線段的問題。
: : 對偶的時候,點(a,b)對偶成直線y=ax+b。
: : 考慮兩個直線的交點,也就是兩條直線解聯立方程式。
: : 根據公式解,交點的座標範圍一定會在 |a|*|b|+|c|*|d| 之內。
:
: First, I don't understant your notation.
: What do you mean by the range |a|*|b|+|c|*|d| ?
:
: It seems not a range in 2D ?
:
:
: And I have the same question for you.
:
: Assume you have N lines, based on your description
: You claim there is a range for the intersection.
:
: Then, how many operations you need to calculate the range?
:
:
:
作者: DJWS (...)   2012-02-13 15:51:00
恩 你說的沒錯 那麼範圍最大到 |d|+|b| 才對
作者: Leon (Achilles)   2012-02-13 15:53:00
you are wrong again, look, there is (a-c) term!
作者: DJWS (...)   2012-02-13 15:55:00
恩 你說的沒錯 除非abcd都是整數 範圍才是 |d|+|b|
作者: Leon (Achilles)   2012-02-13 15:56:00
then revise your post. Everyone should be responsible towhat they write
作者: DJWS (...)   2012-02-13 15:59:00
這是當然 XD
作者: Leon (Achilles)   2012-02-14 01:24:00
OK, your first statement is wrong. Now you can answerthe second question:

Links booklink

Contact Us: admin [ a t ] ucptt.com