I looked at another post that described what seems like my problem :
How to make a method that accepts any number of arguments of any type in Java?
However , when I tried to make this method, when I compiled the program that it gave me, the error "int could not be converted to java.util.Objects"
What am I doing wrong?
code:
public static void clearArray (Objects... args)
{
System.out.println("Error, non character value");
}
As I called the function:
import java.util.Objects;
clearArray(1);
Thanks for watching my problem!
source
share