can I import,use class from other package? In Eclipse I made 2 packages one is main other is second
main -main (class) second -second (class)
and I w
Given your example, you need to add the following import in your main.main class:
import second.second;
Some bonus advice, make sure you titlecase your class names as that is a Java standard. So your example Main class will have the structure:
package main; //lowercase package names
public class Main //titlecase class names
{
//Main class content
}