In this task, you are given an input list A. You need to find all the elements of the list that are numbers and calculate their sum.
['M', '4749', 'p', 'X', '2831', '7479', 'P', 'T', 'T', 'f', '5977', '5165', '7397', '4049']