SHARE
TWEET

Untitled

a guest Jun 19th, 2019 64 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. char[] arr = {'a','b','c','','',''};
  2. int len = 0;
  3. do {
  4.   len++;
  5. } while (arr.length > len && arr[len] != '');
  6. String s = new String(arr, 0 ,len);
  7. System.out.println(s); // abc
  8.      
  9. String s = String.valueOf(bits).trim();
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top