Java examples for java.lang:char
is Connector Character
//package com.java2s; public class Main { public static void main(String[] argv) throws Exception { char ch = 'a'; System.out.println(isConnector(ch)); }/*from www . j a v a 2 s . co m*/ public static final char[] connectors = new char[] { '+', '#', '&', '.', '_', '-' }; public static boolean isConnector(char ch) { for (char connector : connectors) if (ch == connector) return true; return false; } }