确定是否可以从分配课程
//package com.nowjava; /** 来 自 NowJava.com - 时代Java **/ public class Main { /** * Determine if classes can be assigned from * * @param c1 first array of classes * @param c2 second array of classes * @return true if c1 array can be assigned from c2 array */ public static boolean isAssignable(Class[] c1, Class[] c2) { if (c1 == null || c2 == null) return false; if (c1.length != c2.length) return false; for (int i = 0; i < c1.length; i++) { if (!c1[i]