Implements random operation within class as in Integer