why we write system.in when we are taking input from the user?
Meaning of system.in
Hi Mansi
We write
Scanner scn = new Scanner(System.in)
while taking an input. Here .in is an object defined in the “Input Stream” class in System class. System.in in java means to take input from the keyboard or the user.
Hi Mansi
As you are not responding to this thread, I am marking your doubt as Resolved for now. Re-open it if required.
Please mark your doubts as resolved in your course’s “ Ask Doubt ” section, when your doubt is resolved.
.in is an object of which class input stream or system?
Hi Mansi
.in is a member of the System class.