First solution in Clear category for Replace Last by katnic
replace_last = lambda L: [L[-1]] + L[:-1] if L else L
Aug. 19, 2021