Praseodymium has 59 electrons arranged as 2, 8, 18, 21, 8, 2 across 6 shells, which is why it sits in period 6.
How to write it
Start from the previous noble gas core, written in square brackets, then add the remaining electrons in filling order. For praseodymium that gives [Xe] 4f3 6s2.