Adding printf statement similar to cout statement.