2023年2月26日碰撞演算法

2021-04-15 09:28:31 字數 1120 閱讀 8506

修改了後,一定要重新整理一下工程再執行。

碰撞演算法

public static boolean intersectrect(int r1x1, int r1y1, int r1x2, int r1y2,

int r2x1, int r2y1, int r2x2, int r2y2)

*   detect   rectangle   intersection  

*    

*   @param   r1x1   left   co-ordinate   of   first   rectangle  

*   @param   r1y1   top   co-ordinate   of   first   rectangle  

*   @param   r1x2   right   co-ordinate   of   first   rectangle  

*   @param   r1y2   bottom   co-ordinate   of   first   rectangle  

*   @param   r2x1   left   co-ordinate   of   second   rectangle  

*   @param   r2y1   top   co-ordinate   of   second   rectangle  

*   @param   r2x2   right   co-ordinate   of   second   rectangle  

*   @param   r2y2   bottom   co-ordinate   of   second   rectangle  

*   @return   true   if   there   is   rectangle   intersection  

*/  

private   boolean   intersectrect(int   r1x1,   int   r1y1,   int   r1x2,   int   r1y2,    

int   r2x1,   int   r2y1,   int   r2x2,   int   r2y2)     else    

}

2023年05月26日辦公室隨筆

記憶裡面已經好久沒有維護這個部落格了,只是時而一年半載的進來看一下,以確認我的部落格是否還在 應該有將近3年了吧。3年,過得飛快,從一家公司跳到了另一家公司,從25歲跳到了28歲,從當初的躊躇滿志到現在的 胸無大志 依然我還沒有找到心儀的她,房子也還沒有買,說起來挺汗的。在現在的公司已經呆了將近3年...

日誌2月26日

題目 test dict 輸出原始的字典 print 字典移除前 str test dict 使用 del 移除 zhihu del test dict zhihu 輸出移除後的字典 print 字典移除後 str test dict 移除沒有的 key 會報錯 輸出原始的字典 print 字典移除...

2023年9月3日 8月29 9月2日沒寫

2008年9月3日 8月29 9月2日沒寫 給同學的郵件 5 我這幾天除了遊一次泳,週末接連喝了2次酒,還和老二他們週六打了一宿的麻將,似乎有些自找麻木了。這段時間,專案不忙,隱約感覺外包 有些動盪,也不知職位是否也危險了,總之目前不太想自己的工作了,工作熱情談不上,只能說是稍微認真一點,能夠按時完...