(Disclaimer: I'm an Arch user, never used Slackware.)
The program that prints the quotes is usually called fortune. It's available on most distros I have used, but the specific set of quotes may vary. Look in /etc/profile, or in scripts in /etc/profile.d for mentions of fortune. According to the description of the bsd-games package:
Adds a call to 'fortune' to /etc/profile.d/ so that users will get a fortune message when they log in.
The mail message is usually printed by pam_mail, a PAM plugin, but I think Slackware does not use PAM (What are the reasons Slackware still refuses to include PAM?).
According to this Linux Questions forum post for Slackware 14, the mail notification is also printed due to commands in /etc/profile:
...
# Notify user of incoming mail. This can be overridden in the user's
# local startup file (~/.bash.login or whatever, depending on the shell)
if [ -x /usr/bin/biff ]; then
biff y 2> /dev/null
fi
...