Rectangles Total Area

Find the total area covered by a list of rectangles.

Easy1/22/2024

Problem statement

Given a list of rectangles defined by their top-left corner coordinates and their width and height (all are positive integers), find the total area covered by the rectangles. The rectangles may overlap.

Problem leaderboard

#
Size
%
Users
#1
69 c.
Top 9%
Steffan
#2
79 c.
Top 27%
Natanaelel
tree
#3
81 c.
Top 36%
voytxt
#4
86 c.
Top 45%
CorentinTh
#5
91 c.
Top 55%
Thomasdcrt
#6
95 c.
Top 64%
Tony
#7
98 c.
Top 73%
scpchicken
#8
100 c.
Top 82%
maximec-indy
#9
110 c.
Top 91%
Pascal
#10
113 c.
Top 100%
davyboyh