Added random function

made changes to main function and also added a function that will print
two different outputs.