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.
7, ['3843', 'D', '8577', '6477', '3', 'N', 'i', '8077', 'r', '425', '8925', '2427', '8331', 'C', '4539', '7663', 'H', '9385', '1021', '1005', '3133', '6801', '899', '2967']