हिंदी

Explain the following function: next(); - Computer Applications

Advertisements
Advertisements

प्रश्न

Explain the following function:

next();

संक्षेप में उत्तर

उत्तर

When a line of text is entered into the Scanner object, the next() method will only get the first token. 

Syntax:

Scanner ob = new Scanner(System.in); 
String s = ob.next();
shaalaa.com
  क्या इस प्रश्न या उत्तर में कोई त्रुटि है?
अध्याय 1.06: Input in Java - EXERCISES [पृष्ठ ६६]

APPEARS IN

अविचल Computer Applications [English] Class 10 ICSE
अध्याय 1.06 Input in Java
EXERCISES | Q III. 3. | पृष्ठ ६६
Share
Notifications

Englishहिंदीमराठी


      Forgot password?
Use app×