Use pop instead of assign plus later pop