We read your photo as:
Write an algorithm to draw a regular polygon with n sides of length s.
Computer Science
ScanSolve AI Answer
Here is the continuation of your algorithm to the drawing stage:
Begin
input number of sides n
input side length s
SET turn_angle = 360 / n
REPEAT n times:
MOVE FORWARD s steps
TURN RIGHT turn_angle degrees
End
Was this helpful?
Still stuck on this one?
Ask a follow-up, and the answer starts from this question.
Got a different question?Ask your own question
More Computer Science Questions
QAlgorithm: Draw Regular PolygonQIdentify and draw common polygons, specifying the number of sides for each. Ensure unequal sides for…QThe ratio of the sum of interior angles of two regular polygons, one with n sides and another with…QA regular polygon of n sides is such that each interior angle is 120^ exto greater than the exterior…QDraw in all the lines of symmetry for each regular polygon. Complete the table.
Browse by topic:Algorithms