import java.util.*;
import java.util.zip.*;
import java.util.List;
import java.util.regex.*;
import java.util.concurrent.*;
import java.util.concurrent.atomic.*;
import java.util.concurrent.locks.*;
import javax.swing.*;
import javax.swing.event.*;
import javax.swing.text.*;
import javax.swing.table.*;
import java.io.*;
import java.net.*;
import java.lang.reflect.*;
import java.lang.ref.*;
import java.lang.management.*;
import java.security.*;
import java.security.spec.*;
import java.awt.*;
import java.awt.event.*;
import java.awt.image.*;
import javax.imageio.*;
import java.math.*;
class main {
public static void main(final String[] args) throws Exception {
assertTrueVerbose(allContainAllCharsIC(ll("abc", "ADEC"), "ca"));
assertTrueVerbose(allContainAllCharsIC(ll("abc", "ADEC"), "ac"));
assertFalseVerbose(allContainAllCharsIC(ll("abc", "ADE"), "ca"));
assertFalseVerbose(allContainAllCharsIC(ll("abc", "ADEC"), "cax"));
}
static List ll(A... a) {
ArrayList l = new ArrayList(a.length);
for (A x : a) l.add(x);
return l;
}
static void assertTrueVerbose(Object o) {
assertEqualsVerbose(true, o);
}
static boolean allContainAllCharsIC(Collection l, String chars) {
List charList = charsAsList(upper(chars));
for (String s : unnull(l)) {
HashSet set = asHashSet(charList);
removeAll(set, charsAsList(upper(s)));
if (nempty(set)) return false;
}
return true;
}
static void assertFalseVerbose(Object o) {
assertEqualsVerbose(false, o);
}
static Map _registerThread_threads = newWeakHashMap();
static Thread _registerThread(Thread t) {
_registerThread_threads.put(t, true);
return t;
}
static void _registerThread() { _registerThread(Thread.currentThread()); }
static HashSet asHashSet(Collection c) {
synchronized(collectionMutex(c)) {
return new HashSet(c);
}
}
static HashSet asHashSet(A[] a) {
return a == null ? null : new HashSet(Arrays.asList(a));
}
static List charsAsList(final String s) {
return stringAsCharacterList(s);
}
static String upper(String s) {
return s == null ? null : s.toUpperCase();
}
static String unnull(String s) {
return s == null ? "" : s;
}
static List unnull(List l) {
return l == null ? emptyList() : l;
}
static Map unnull(Map l) {
return l == null ? emptyMap() : l;
}
static Iterable unnull(Iterable i) {
return i == null ? emptyList() : i;
}
static A[] unnull(A[] a) {
return a == null ? (A[]) new Object[0] : a;
}
static BitSet unnull(BitSet b) {
return b == null ? new BitSet() : b;
}
static boolean nempty(Collection c) {
return !isEmpty(c);
}
static boolean nempty(CharSequence s) {
return !isEmpty(s);
}
static boolean nempty(Object[] o) {
return !isEmpty(o);
}
static boolean nempty(Map m) {
return !isEmpty(m);
}
static boolean nempty(Iterator i) {
return i != null && i.hasNext();
}
static Map newWeakHashMap() {
return _registerWeakMap(synchroMap(new WeakHashMap()));
}
static void removeAll(Collection a, Collection b) {
if (a != null && b != null) a.removeAll(b);
}
static void assertEqualsVerbose(Object x, Object y) {
assertEqualsVerbose((String) null, x, y);
}
static void assertEqualsVerbose(String msg, Object x, Object y) {
if (!eq(x, y))
throw fail((msg != null ? msg + ": " : "") + sfu(y) + " != " + sfu(x));
else
print("OK: " + sfu(x));
}
static Map synchroMap() {
return synchroHashMap();
}
static Map synchroMap(Map map) {
return Collections.synchronizedMap(map);
}
static String sfu(Object o) { return structureForUser(o); }
static String emptySymbol_value;
static String emptySymbol() {
if (emptySymbol_value == null) emptySymbol_value = symbol("");
return emptySymbol_value;
}
static List emptyList() {
return new ArrayList();
//ret Collections.emptyList();
}
static List emptyList(int capacity) {
return new ArrayList(capacity);
}
// Try to match capacity
static List emptyList(Iterable l) {
return l instanceof Collection ? emptyList(((Collection) l).size()) : emptyList();
}
static Map emptyMap() {
return new HashMap();
}
static boolean isEmpty(Collection c) {
return c == null || c.isEmpty();
}
static boolean isEmpty(CharSequence s) {
return s == null || s.length() == 0;
}
static boolean isEmpty(Object[] a) {
return a == null || a.length == 0;
}
static boolean isEmpty(Map map) {
return map == null || map.isEmpty();
}
static boolean eq(Object a, Object b) {
return a == null ? b == null : a == b || a.equals(b);
}
// a little kludge for stuff like eq(symbol, "$X")
static RuntimeException fail() { throw new RuntimeException("fail"); }
static RuntimeException fail(Throwable e) { throw asRuntimeException(e); }
static RuntimeException fail(Object msg) { throw new RuntimeException(String.valueOf(msg)); }
static RuntimeException fail(String msg) { throw new RuntimeException(msg == null ? "" : msg); }
static RuntimeException fail(String msg, Throwable innerException) { throw new RuntimeException(msg, innerException); }
static volatile StringBuffer local_log = new StringBuffer(); // not redirected
static volatile StringBuffer print_log = local_log; // might be redirected, e.g. to main bot
// in bytes - will cut to half that
static volatile int print_log_max = 1024*1024;
static volatile int local_log_max = 100*1024;
//static int print_maxLineLength = 0; // 0 = unset
static boolean print_silent; // total mute if set
static Object print_byThread_lock = new Object();
static volatile ThreadLocal