Build the rows
The outer counter x advances through A to E while the inner range loses one iteration on each row.
The rows repeat A five times, B four times, C three times, D twice, and E once.
The outer counter x advances through A to E while the inner range loses one iteration on each row.
chr(x + 65) selects one letter and the inner loop prints that letter for the row length.
The inner print calls use end="" to keep values on the same line. The final empty print() moves to the next row.