CS Explanation

Embed Size (px)

Citation preview

  • 8/18/2019 CS Explanation

    1/1

    Stella Connaughton10.20.15

    Explanation

     To create this program, I had to be able to use the function choose true

    !probabilit"#fTrue$ of the time%. I set probabilit"#fTrue to 0.&. I then created an

    If'Else control statement for the custom method. I set (If choose true !0.&$ of the

    time), and underneath put the code in so that bi*e+id ill mo-e forard. Therefore,

    I rote that &0 of the time, bi*e+id ill mo-e forard 5 meters. /or the Else

    statement, I put that he orients himself to the road, so he faces the direction of the

    other road, and he mo-es forard, so he ma*es a turn. Since &0 of the time he

    ill mo-e forard, 0 of the time he ill ma*e a turn.