Skip to content

calculation the number of squares whose sides are folded in one direction

Notifications You must be signed in to change notification settings

AnnaVyvert/paper-task

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 

Repository files navigation

paper-task

Calculation the number of squares whose sides are folded in one direction.

The paper is folded by four instructions:

A = 0 (vertical) left side of the paper on the right, upward

B = 2 (vertical) left side of the paper on the right, down

C = 1 (horizontal) underpart of the paper to the top, upward

D = 3 (horizontal) underpart of the paper to the top, down

number of the horizontal squares = even number of the vertical squares = odd

input: n - the number of randomly generated instructions.

after the calculation, a graphical view of the paper is displayed. then the number of squares whose sides are folded in one direction is displayed.

About

calculation the number of squares whose sides are folded in one direction

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published