I'm looking at this tutorial about BufferedReader at youtube
https://www.youtube.com/watch?v=yofFVbARIRU
I write the code exactly as he does but I can't get it to work. I cant get the BufferedReader code to work even though I imported it with
import java.io.*;
InputStreamReader stream = new InputStreamReader(System.in);
BufferedReader reader = new BufferedReader (stream);
I solved it with this code:
InputStreamReader stream = new InputStreamReader(System.in);
java.io.BufferedReader reader = new java.io.BufferedReader (stream);
And this works as well:
java.io.BufferedReader reader =
new java.io.BufferedReader (new InputStreamReader(System.in));
Could someone explain to me what's wrong in the first code? Because it works for him who's giving the tutorial