Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVA

String to Byte array Java

import java.util.Arrays;

public class StringToByte {
 public static void main(String[] args) {
  String str = "Example String";
  byte[] b = str.getBytes();
  System.out.println("Array " + b);
  System.out.println("Array as String" + Arrays.toString(b));
 }
}
Source by www.netjstech.com #
 
PREVIOUS NEXT
Tagged: #String #Byte #array #Java
ADD COMMENT
Topic
Name
9+6 =