A substitute teacher rapped an inspirational message to his class and went viral