added functions for operations and printing