modified for learning
add to last