Main.java:2: error: class avg is public, should be declared in a file named avg.java
public class avg {
^
Main.java:9: error: no suitable method found for println(String,int,String)
System.out.println("Enter the %d",+i ,"th subject marks");
^
method PrintStream.println() is not applicable
(actual and formal argument lists differ in length)
method PrintStream.println(boolean) is not applicable
(actual and formal argument lists differ in length)
method PrintStream.println(char) is not applicable
(actual and formal argument lists differ in length)
method PrintStream.println(int) is not applicable
(actual and formal argument lists differ in length)
method PrintStream.println(long) is not applicable
(actual and formal argument lists differ in length)
method PrintStream.println(float) is not applicable
(actual and formal argument lists differ in length)
method PrintStream.println(double) is not applicable
(actual and formal argument lists differ in length)
method PrintStream.println(char[]) is not applicable
(actual and formal argument lists differ in length)
method PrintStream.println(String) is not applicable
(actual and formal argument lists differ in length)
method PrintStream.println(Object) is not applicable
(actual and formal argument lists differ in length)
Main.java:16: error: no suitable method found for println(String,double)
System.out.println("The avg is",+avg);
^
method PrintStream.println() is not applicable
(actual and formal argument lists differ in length)
method PrintStream.println(boolean) is not applicable
(actual and formal argument lists differ in length)
method PrintStream.println(char) is not applicable
(actual and formal argument lists differ in length)
method PrintStream.println(int) is not applicable
(actual and formal argument lists differ in length)
method PrintStream.println(long) is not applicable
(actual and formal argument lists differ in length)
method PrintStream.println(float) is not applicable
(actual and formal argument lists differ in length)
method PrintStream.println(double) is not applicable
(actual and formal argument lists differ in length)
method PrintStream.println(char[]) is not applicable
(actual and formal argument lists differ in length)
method PrintStream.println(String) is not applicable
(actual and formal argument lists differ in length)
method PrintStream.println(Object) is not applicable
(actual and formal argument lists differ in length)
3 errors