Yahoo Answers is shutting down on 4 May 2021 (Eastern Time) and the Yahoo Answers website is now in read-only mode. There will be no changes to other Yahoo properties or services, or your Yahoo account. You can find more information about the Yahoo Answers shutdown and how to download your data on this help page.
AV
I'm just another happy-go-lucky... no just another next door girl in this world
Need Python help - greedy algorithm distances?
Hello... I have no idea where to even start on this question appreciate any guidance:
You have two equal length lists of (a,b) points: x and y.
Write a python function with the signature given below that computes all possible distances between x and y using a greedy algorithm to return a list of (index_of_x_element, index_of_y_element) pairs with pairwise distances sorted from smallest to largest.
Assume no replacement, i.e. any x or y element is used exactly once.
def sort_pair_dist(x, y):
"""
Input:
x,y are a list of a, b points
x = [(x_a0,x_b0), (x_a1,x_b1),…]
y = [(y_a0,y_b0), (y_a1,y_b1),…]
Output:
p = [(x_index10,y_index3), (x_index1,y_index6),…]
"""
return p
Programming & Design3 weeks agoPhysics - electrical charge, current and circuits?
um cn sm1 tell me how to do question 5 from the link below??
1 AnswerPhysics1 decade agoPhysics - electricity and charge?
As a rough guide, copper wires can conduct about 10 A mm^2 before overheating and there are approximately 10^20 free electrons per mm^3 in copper.
find:
2) The length of wire with cross section 1 mm^2 cotaining 6.25x10^19
1 AnswerPhysics1 decade agocan some one ans this a-level m1 question?
A particle has mass 2 kg. It is attached at B to the ends of two light inextensible strings AB and BC. When the particle hangs in equilibrium AB makes an angle of 30 degrees with the vertical. The magnitude of the tension in BC is twice the magnitude of the tension in AB.
(a) Find in degrees to one decimal place, the size of the angle that BC makes with the vertical. (4 marks)
(b) Hence find to 3 significant figures the magnitude of the tension in AB. (4 marks)
have answers but how do i do the workin?? sm1 plzz help
answers
a) 14.5 deg
b) 6.99N
1 AnswerMathematics1 decade agoA-LEVEL Physics - Energy?
A hydroelectric power station has an efficiency of 25%. The water driving the turbine falls through a height of 300m before reaching the turbines. Calculate the volume of water that must pass through the turbines each second to give a power output of 2MW. Assume the density of water is 1000kgm-3
1 AnswerPhysics1 decade agohow is mass related to viscosity?
5 AnswersPhysics1 decade agodoes bromine water go colourless when mixed...?
does bromine water go colourless when mixed with ethanol?? and why??
1 AnswerChemistry1 decade agoFrench - Hard task bt worth it :)?
k can sm1 plzz write me a 150 word passage on protectin da enivironnement in french :)
plzz include: perfect + imperfect tense, present, future + conditinal (if possible) tense and add an opinion like je pense que...
Hurry... Best 1 getz da prize :)
5 AnswersLanguages1 decade agoHas anyone had their edexcel french orals 2009? (edexcel)?
if you have... wat c-role-plays did you have 2 do??
wat were dey about?? and wat was ur chosen topic??
1 AnswerStandards & Testing1 decade agohas anyone had their edexcel french orals 2009?
if you have... wat c-role-plays did you have 2 do??
wat were dey about??
2 AnswersStandards & Testing1 decade agoCould it be breast cancer?
my right nipple is extremely painful and its gone really pink and the pain goes to a point that it starts to feel numb!! could this be cancer of does it happen to people before menstruation? coz its never happened to me before please tell me?? i'm only 17!! is this normal????
7 AnswersCancer1 decade agocould it be breast cancer?
my right nipple is extremely painful and its gone really pink and the pain goes to a point that it starts to feel numb!! could this be cancer of does it happen to people before menstruation? coz its never happened to me before please tell me?? i'm only 17!! is this normal????
3 AnswersCancer1 decade agoi've got nipple thrush n it really hurts! can someone advise please?
i've got nipple thrush i think (i'm not breastfeeding or any thing), n i need to treat it at home!
what do i do?? will an antibacterial ointment work?
please it is really painful
4 AnswersSTDs1 decade agoi've got nipple thrush n it really hurts! can someone advise please?
i've got nipple thrush i think (i'm not breastfeeding or any thing), n i need to treat it at home!
what do i do?? will an antibacterial ointment work?
please it is really painful
4 AnswersSTDs1 decade agoi've got nipple thrush n it really hurts! can someone advise please?
i've got nipple thrush i think (i'm not breastfeeding or any thing), n i need to treat it at home!
what do i do?? will an antibacterial ointment work?
please it is really painful
1 AnswerSTDs1 decade agoi've got nipple thrush n it really hurts! can someone advise please?
i've got nipple thrush i think (i'm not breastfeeding or any thing), n i need to treat it at home!
what do i do?? will an antibacterial ointment work?
please it is really painful
3 AnswersSTDs1 decade agoEst-ce que tu verras la pièce de théâtre au collège?
guys could you give some detailed answers plzzzzzz coz i'm not so gd at french plzzzzzzzzzzzzzzzzzzzzz
:)
3 AnswersLangues1 decade ago