r for random class

huge update