java string from byte array

java string from byte array
re‮ef‬r to:lautturi.com
/**
 * @author lautturi.com 
 * Java example: java string from byte array
 */

import java.nio.charset.StandardCharsets;
import java.util.*;

public class Lautturi {
	public static void main(String[] args) {
		
		byte[] bytes = {104, 101, 108, 108, 111, 32, 106, 97, 118, 97};
		String str = new String(bytes, StandardCharsets.UTF_8);
		
		System.out.println(str);
	}
}

output:

hello java
Created Time:2017-09-30 18:05:58  Author:lautturi