add README and use a loop in client