if this is the last porfolio, print the total

if(next(ptr) == null)

printf("\n Portfolio value is

%12.2f \n",total);