I've been watching videos and doing tutorials but i still don't understand the difference between these two things. Can anyone help?
class Example{ public void printHi(){ printString("Helooooo"); } private void printString(String str){ System.out.println(str); } }
Example e1 = new Example(); e1.printHi();
Example e1 = new Example() e1.printString("Heloooo");