Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Can you help me to create this Python program? I am really confused how to creat

ID: 3670015 • Letter: C

Question

Can you help me to create this Python program? I am really confused how to create this program. Thnak you!

CS161 Assignment 4 Program: Three-shot Archery are marked with 10 evenly spaced concentric rings, which have score values from According to http://en.wikipedia.org/wiki/Target archery, standard FITA targets ccording to http /len wikipedia.ors/wiki/Target archery, standard FITA tar 1 through 10 assigned to them. In FITA archery, targets are colored as follows: 1 ring & 2 ring- white 3 ring & 4 ring-black 5 ring&6 ring-blue 7 ring & 8 ring red #9 ring, 10 ring-gold

Explanation / Answer

       def target():

                     ringColors=["white","white","black","black","blue","blue","red","red","gold","gold"];

                     var i=0,rad=50,cir=10;

                 while(cir>0):

                       turtle.circle(50);

                       turtle.fillcolor(ringColors[i]);

                       turtle.begin_fill();

                       turtle.end_fill();

                       cir--;

                       rad=rad-5;

                end

          end

   def shoot:

          turtle.forward(-75);

          var x=random.randrange(0,101,2);

          var y=random.randrange(0,101,2);

         turtle.setpos(x,y);

        turtle.dot(10,"pink");

       return math.sqrt(x*x+y*y);

end

def score(dis,tem):

            if(tem==1):

                      sum=0;

           else :

           end

                   sum=sum+dis;

end

def prog():

         target();

        var i=3;

           while(i>0):

                       var l;

                    var temp=shoot();

                    if(i==1):

                               l=1;

                    else:

                               l=2;

                    score(temp,l);

                       i--;

            end

end

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote