What is the difference between a Java API and a library?
<p>I know that an API is called a set of functions used to call something, and a library is a collection of classes, but what is actually API in package like <code>java.lang</code>? I can connect to a class like <code>System</code> without using any API here, so why we say as J2SE API rather than J2SE packages?</p>
