updated style and adjusted prime facter function