improved readability and memory usage