Java examples for java.lang:char
is Symbol
//package com.java2s; public class Main { public static void main(String[] argv) throws Exception { char c = 'a'; System.out.println(isSymbol(c)); }/*from w w w . j a va 2 s . com*/ public static boolean isSymbol(char c) { return c == '/' || c == '.' || c == '&' || c == '|' || c == '-' || c == '+' || c == '=' || c == '<' || c == '>' || c == '!' || c == '?' || c == '~' || c == '[' || c == ']' || c == '{' || c == '}' || c == ',' || c == ';' || c == ':' || c == '$' || c == '=' || c == '*' || c == '%' || c == '^' || c == '(' || c == ')'; } }