changed the parameters to have more arguments
added store function