diff options
| author | E7-87-83 <fungcheokyin@gmail.com> | 2022-02-21 06:41:36 +0800 |
|---|---|---|
| committer | E7-87-83 <fungcheokyin@gmail.com> | 2022-02-21 06:41:36 +0800 |
| commit | b77e7339ff36bfcd47a7c1464d43e9fd8bb935e8 (patch) | |
| tree | a5f4481c3e73d8afe683dd9987ee6e61acc4c4fd | |
| parent | ce4353477c8001d22b0a7879fa8181514fcfb278 (diff) | |
| download | perlweeklychallenge-club-b77e7339ff36bfcd47a7c1464d43e9fd8bb935e8.tar.gz perlweeklychallenge-club-b77e7339ff36bfcd47a7c1464d43e9fd8bb935e8.tar.bz2 perlweeklychallenge-club-b77e7339ff36bfcd47a7c1464d43e9fd8bb935e8.zip | |
Week 152 Task 2
| -rw-r--r-- | challenge-152/cheok-yin-fung/perl/ch-2.pl | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/challenge-152/cheok-yin-fung/perl/ch-2.pl b/challenge-152/cheok-yin-fung/perl/ch-2.pl index d138469ec0..d71e2a3c4b 100644 --- a/challenge-152/cheok-yin-fung/perl/ch-2.pl +++ b/challenge-152/cheok-yin-fung/perl/ch-2.pl @@ -50,10 +50,10 @@ sub rect_area { }} =pod - Except one rectangle is inside the other rectangle, + Except the case that one rectangle is inside the other rectangle, the two rectangles can be enscribed into a larger rectangle - I divided the larger rectangle into 9 small rectangular regions; - then check if each small regions is inside rect. A or rect. B. + Dividing the large rectangle into 9 small rectangular regions, + then check one by one if a small region is inside rect A or rect B. If yes, add the area of the small region into $area. =cut |
