In this task, you are given inputs i and A, where i is an integer and A is a list. You need to list all the elements of A preceding the last i elements. i will always have a value less than the length of A.
5, ['k', 'D', 'n', 'p', 'H', '8161', '1557', 'B', '6085', 'I', '4069', '9719', '4821', '8923', 'R', '3271', 't']