second() function added into the code first.R