0

I am new to java and my question is how do i accept charecters in my programs? And also how to convert it into uppercase letter?

26th Jun 2017, 11:25 AM
Avash Mitra
Avash Mitra - avatar
4 odpowiedzi
+ 4
inputs? Extracted from https://cheeze.club/w7db Scanner reader = new Scanner(System.in); // Reading from System.in System.out.println("Enter a number: "); int n = reader.nextInt(); // Scans the next token of the input as an int. Converting to uppercase: um the .toUpperCase() method i guess
26th Jun 2017, 11:31 AM
David Sebastian Keshvi Illiakis
David Sebastian Keshvi Illiakis - avatar
+ 3
You can use reader.nextLine(); if you want.
26th Jun 2017, 11:41 AM
J.G.
J.G. - avatar
+ 2
26th Jun 2017, 11:56 AM
Yanothai Chaitawat
Yanothai Chaitawat - avatar
+ 1
I mean how to accept alphabets like-- a,b etc
26th Jun 2017, 11:33 AM
Avash Mitra
Avash Mitra - avatar