<?php $_POST['enrolled_term'] = array(1, 2, 3, 4, 5); echo $lastElement = array_values(array_slice($_POST['enrolled_term'], -1))[0]; ?>
You have javascript disabled. You will not be able to edit any code.