Python Forum
compare and find the nearest element ?
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
compare and find the nearest element ?
#1
hello,
I need a little help, I have a list (element has 2 elements(X and Y)), and I need to find, in this list, which element is the nearest of my mouse (we have already X and Y of the mouse).
Can you help me please ?

Also, can you know how can I wrote "move away" for evade if they are bomb in approach ? like " Xbomb - 30px ", can it work ?

PS : I'm french, sorry if I make misstake in my message... Doh
Reply


Messages In This Thread
compare and find the nearest element ? - by mr_gentle_sausage - Jan-14-2023, 09:32 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Writing a cycle to find the nearest point from the array Tysrusko 0 247 May-10-2024, 11:49 AM
Last Post: Tysrusko
  Get numpy ceil and floor value for nearest two decimals klllmmm 4 1,475 Jun-07-2023, 07:35 AM
Last Post: paul18fr
  Find (each) element from a list in a file tester_V 3 1,348 Nov-15-2022, 08:40 PM
Last Post: tester_V
  [SOLVED] [Beautifulsoup] Find if element exists, and edit/append? Winfried 2 4,599 Sep-03-2022, 10:14 PM
Last Post: Winfried
  How to find the second lowest element in the list? Anonymous 3 2,199 May-31-2022, 01:58 PM
Last Post: Larz60+
  Compare each element of an array in a logic statement without using a for loop leocsmith 3 6,100 Apr-01-2021, 07:57 PM
Last Post: deanhystad
  Rounding to the nearest eight wallgraffiti 2 2,192 Jul-15-2020, 06:05 PM
Last Post: wallgraffiti
  how to compare two different size images in python and find corresponding pixel value squidsirymchenry 1 4,715 Feb-03-2020, 06:48 AM
Last Post: michael1789
  find nearest number d3fi 7 4,204 Aug-26-2019, 09:32 PM
Last Post: ichabod801
  Finding nearest point of a Multidigraph in Python 3.7 stixmagiggins 5 3,956 Aug-24-2019, 08:51 AM
Last Post: ThomasL

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020