The commands might not be doing what you think. In reverse order, because A is correct.
D. javac -D a=b c_d
C. javac -Da=b c_d
C and D are wrong because javac has no command line parameter "-D". On both accounts it will complain with a "javac: invalid flag" error (and show help).
B.
java -D a=b c_d
This isn't going to work for a number of reasons. First, you can ignore the -D because it doesn't do anything in this case (see following explanation). As you noted, you can't name a class with an = sign. The file won't compile and if you name the class something else inside the file, then they are kept at the package protection level and won't be found by the java classloader.
A. java -Da=b c_d
This works because it sets a system property named "a" to the value "b". It then looks for and loads the class named "c_d" from the classpath.