Java Char Array to Char charArrayToLowerCase(char[] arr)

Here you can find the source of charArrayToLowerCase(char[] arr)

Description

char Array To Lower Case

License

Open Source License

Declaration

public static char[] charArrayToLowerCase(char[] arr) 

Method Source Code

//package com.java2s;
//License from project: Open Source License 

public class Main {
    public static char[] charArrayToLowerCase(char[] arr) {
        char[] result = new char[arr.length];
        for (int i = 0; i < result.length; ++i) {
            result[i] = arr[i] > 0x40 && arr[i] < 0x5B ? (char) ((int) arr[i] + 0x20) : arr[i];
        }//from  w w  w  .jav a 2 s.  c o  m
        return result;
    }
}

Related

  1. charAt(char[] s, int pos)
  2. charAt(CharSequence chars, int i)
  3. charAt(CharSequence chars, int index, boolean ignoreCase)
  4. hasCharAt(char toLookFor, int position, char[] toSearch)