The answer at slide 16 is that numOfSample can be calculated only if Audio Format is PCM, otherwise is meaningless!

Introductory Lecture to Audio Signal Processing by Angelo Antonio Salatino is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.