Coursera (implement by java)