added functions that dont need int pointer for length