M
M
MrShaggy2017-03-12 18:52:33
Java
MrShaggy, 2017-03-12 18:52:33

Why is classpath definition necessary in java and javac?

Good day!
I am writing an application that uses third-party libraries. I was perplexed when I saw the classpath option for java and javac in help .
After not very successful attempts to learn about this circumstance in English google a little more than " Classpath is a parameter in the Java Virtual Machine or the Java compiler that specifies the location of user-defined classes and packages. ", came to you.
I understand why the classpath needs to be defined. I don't see why it might (or might not) need to be done at both compile time and run time. Hope you can shed some light on me.
Thank you!

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question