發表文章

Privacy Policy - Games Database - MHRise

  Privacy Policy Hey Tsai built the  Games Database - MHRise  app as an Ad Supported app. This SERVICE is provided by Hey Tsai at no cost and is intended for use as is. This page is used to inform visitors regarding my policies with the collection, use, and disclosure of Personal Information if anyone decided to use my Service. If you choose to use my Service, then you agree to the collection and use of information in relation to this policy. The Personal Information that I collect is used for providing and improving the Service. I will not use or share your information with anyone except as described in this Privacy Policy. The terms used in this Privacy Policy have the same meanings as in our Terms and Conditions, which is accessible at  Games  Database - MHRise unless otherwise defined in this Privacy Policy. Information Collection and Use For a better experience, while using our Service, I may require you to provide us with certain personally identifiable information. The informati

演算法練習: Kick Start 2020 Round B Wandering Robot

圖片
最近在練習用推導的方式來解演算法問題,在寫4月的Kick Start題目時,遇到一題推導的思路還可以,嘗試把過程整理起來,讓自己能更習慣。 題目連結: https://codingcompetitions.withgoogle.com/kickstart/round/000000000019ffc8/00000000002d8565 簡單描述一下: 有一塊大小 n * m 場地,每一格是 1 * 1 (像七龍珠天下第一武道會的那種石製平台,但長寬可以不同),中間有一個 a * b 的凹洞 (中間的石頭被移掉了)。 你有一個邏輯很簡單的機器人,只會往右或下走,可能性各一半,如果它從左上角出發,那成功到達右下角的機率是多少? 思路1: 時間複雜度: O(n * m) 空間複雜度: O(n * m) 最一開始跳出來的想法,就是依照題目的描述去模擬從左上走到右下,算機率是多少。會需要一個 n * m 的矩陣來紀錄走到每一格的幾率,並需要用2個for迴圈(巢狀)來走過每ㄧ格。 這樣可以滿足第一部分需求,但在第二部分測試的時候,不管是在空間和還是時間上,都沒辦法通過。 程式碼: 所以開始來做優化,主要是從兩個方向來看:有沒有做重複的事,有沒有做多餘的事。 思路2: 時間複雜度: O(max(n,  m)) 空間複雜度: O(max(n,  m)) 從多餘的事來想,因為機器人只能往右和往下走,要掉到凹洞裡,只能從上或左兩個方向,也就是說,當機器人走過凹洞後,就不會再掉進去了。 所以到達終點的機率,會等於 ✖︎ 及 ▲ 處幾率的和,後面到終點的運算都會是多餘的。 因為擔心上面的想法不夠全面,所以把凹洞的位置及形狀做改變,看想法是否還適用。 可以發現,想法還是適用,但要做一點修改,則變成是“所有” ✖︎ 及▲處幾率的和。 另外,再思考的過程,也發現了一件事,因為越過凹洞後,到達終點的機率就不會改變,在凹洞下方或右方增減大小,都不會改變最後的結果 (比較上下圖,最上面的▲處的機率是不變的,第2個▲處機率則為下面的2個的機率和)。 目前省去了超過凹洞後的計算,複雜度的瓶頸變成是如何取得 ✖︎ 處和▲處的機率。 因為是矩陣,直覺有想到 ✖︎ 處和▲處的計算會是對稱

遊戲資料庫 - 魔物獵人世界 (IOS版本)

圖片
魔物及詳細資訊       物品及製作資訊     地圖資訊      搜尋功能 App Store 連結: https://apps.apple.com/app/id1494931573

APP無法取得手機所連接Wi-Fi的SSID

最近修Bug時,遇到了取得的SSID值是 <unknown ssid=""> 的狀況,確認過使用者的定位授權( android.permission.ACCESS_FINE_LOCATION ),也都有正常開啟,一開始以為是特定機種的問題,但後來其他測試機也有類似的狀況,找了下資料,才知道真正的原因。 上述取得SSID的程式碼如下: 在Android 8.1 (API 27)(含)以上版本,APP只擁有使用者的定位權限是不夠的,還需要手機的GPS功能也同時打開才行。 目前看到的結論是,暫時沒有其他的方法可以繞過,一定要上面兩個條件同時滿足,才能拿到正確的SSID。 另外也有文章提到,在理論上就算只有Wi-Fi資訊 (SSID名稱),還是有機會確認出使用者目前的所在位置,所以在保護使用者隱私的原則下,要使用者同意此時可以被定位 (開啟GPS功能),APP才能取得有關使用者位置的資訊,也是相對合理的做法。 資料參考來源: https://stackoverflow.com/questions/21391395/get-ssid-when-wifi-is-connected https://www.davx5.com/faq/wifi-ssid-restriction-location-permission

Privacy Policy - Hey Note - notepad & memo

Privacy Policy Hey Tsai built the Hey Note - notepad & memo app as an Ad Supported app. This SERVICE is provided by Hey Tsai at no cost and is intended for use as is. This page is used to inform visitors regarding my policies with the collection, use, and disclosure of Personal Information if anyone decided to use my Service. If you choose to use my Service, then you agree to the collection and use of information in relation to this policy. The Personal Information that I collect is used for providing and improving the Service. I will not use or share your information with anyone except as described in this Privacy Policy. The terms used in this Privacy Policy have the same meanings as in our Terms and Conditions, which is accessible at Hey Note - notepad & memo unless otherwise defined in this Privacy Policy. Information Collection and Use For a better experience, while using our Service, I may require you to provide us with certain personally identifiable inform

Privacy Policy - Games Database - MHW

Privacy Policy Hey Tsai built the  Games Database - MHW  app as an Ad Supported app. This SERVICE is provided by Hey Tsai at no cost and is intended for use as is. This page is used to inform visitors regarding my policies with the collection, use, and disclosure of Personal Information if anyone decided to use my Service. If you choose to use my Service, then you agree to the collection and use of information in relation to this policy. The Personal Information that I collect is used for providing and improving the Service. I will not use or share your information with anyone except as described in this Privacy Policy. The terms used in this Privacy Policy have the same meanings as in our Terms and Conditions, which is accessible at  Games  Database - MHW unless otherwise defined in this Privacy Policy. Information Collection and Use For a better experience, while using our Service, I may require you to provide us with certain personally identifiable information. The inf

Privacy Policy - QR Code Scanner

Privacy Policy Hey Tsai built the QR Code Scanner app as an Ad Supported app. This SERVICE is provided by Hey Tsai at no cost and is intended for use as is. This page is used to inform visitors regarding my policies with the collection, use, and disclosure of Personal Information if anyone decided to use my Service. If you choose to use my Service, then you agree to the collection and use of information in relation to this policy. The Personal Information that I collect is used for providing and improving the Service. I will not use or share your information with anyone except as described in this Privacy Policy. The terms used in this Privacy Policy have the same meanings as in our Terms and Conditions, which is accessible at QR Code Scanner unless otherwise defined in this Privacy Policy. Information Collection and Use For a better experience, while using our Service, I may require you to provide us with certain personally identifiable information. The information that