Exception in thread "main" java.lang.NoSuchMethodError: main
I know you answered this questions a thousand times, but from all the threads i've read, i understand that it is also a program specific problem. I'm an absolute beginner in Java coding, learning it right now at university... I also undertood from other threads u want me to post in the correct way with the code attached to the message. i hope the form i am posting this thread in is ok... sorry to bother you, but it would be really nice if we could solve this problem somehow:
I created a java file, which compiled without problems; but when i try to run the program, my terminal gives out the failure message stated above.
I already set the classpath variable to the directory i am working in, so i don't think that this is the problem...
anyway, here's the code, hope you can deal with it.
class Widerstand{
//Attribute
float rho;
float laenge;
float flaeche;
publicfloat r;
//Widerstand aus der Formel
Widerstand(float rho,float laenge,float flaeche){
float r=rho*(laenge/flaeche);
}//Formel
//Widerstandswert (direkt 黚ergeben)
Widerstand(float r){
r=r;
}//Wert
//Wert zur點kgeben
float sWert(){
return r;
}
}//class
class Netzwerk{
publicstaticvoid main(String[] args){
float rho=Terminal.askFloat("Rho=");
float laenge=Terminal.askFloat("Leiterlaenge=");
float flaeche=Terminal.askFloat("Leiterdurchmesser=");
}//Argumente
}//class

