Search
 
SCRIPT & CODE EXAMPLE
 

JAVA

java unicode characters

U+0020
U+00A0
U+2002
Comment

unicode in java

/* Java language uses Unicode character set to manage text.
   A character set is an ordered list of characters, each assigned a numeric value.
   In Unicode, each character is represented as a 16-bit numeric value.
   Unicode character table can be found at: https://unicode-table.com/en/
*/

// Digits are assigned numeric values: '0': 48, '1': 49, ..., '9': 57
System.out.println(1 + '0'); // prints 49, the unicode of '1'
System.out.println(1 + '8'); // prints 57, the unicode of '8'

// Uppercase letters: 'A': 65, 'B': 66, 'C': 67, ..., 'Z': 90
System.out.println((char) (1+'B')); // prints letter 'C' out

// Lowercase letters: 'a': 97, 'b': 98, ..., 'z': 122
System.out.println((char) (1 + 'a')); // prints letter 'b' out

// Note that adding 32 to unicode of uppercase letter  
// gives its lowercase equivalent
System.out.println((char) (32 + 'A')); // prints 'a'
System.out.println((char) (32 + 'Z')); // prints 'z'
Comment

unicode in java


String s = Character.toString((char)c);

Comment

PREVIOUS NEXT
Code Example
Java :: check if object is empty java 8 
Java :: how to encrypt password in properties file in spring boot 
Java :: java print array of objects 
Java :: how to create microservices architecture with spring boot 
Java :: abstract class java 
Java :: for loop in java 
Java :: java eth 
Java :: combobox index out of bound javafx 
Java :: writeToFileAsync java 
Java :: how to Compile the source code in ./src folder with libraries in ./lib folder using JavaSE-1.7 
Java :: netbens setdefaultbutton 
Java :: receive an int from terminal java 
Java :: java import keyword 
Java :: read and existing dir content in java 
Java :: how to create a sublist in java 
Java :: jbutton default color 
Java :: input method manager hide keyboard 
Java :: Uri.builder in android studio 
Java :: java test coverage 
Java :: what is difference between constant and final in java 
Java :: springboot request list 
Java :: what is collection fromework 
Java :: java platform runlater keeps running 
Java :: find node from pos linkedlist java 
Java :: charstreams cannot be resolved 
Java :: how to find a specific character in a string using array 
Java :: java remove numbers from set 
Java :: get whatsapp group id flutter 
Java :: ldap java connection 
Java :: android prevent screen from turning off programmatically 
ADD CONTENT
Topic
Content
Source link
Name
9+4 =