Typecasting issue

please give testcase where not typecasting the values to long long int as given in the video code will give the wrong answer