add assertion
add loops