Reflection is used to load java class classes and manipulate them on the fly. But I have across a weird question that is asking me how to create Java classes on the fly by R
You can try ASM ASM
or Byte code engineering library
Byte code engineering library
for manipulating, creating classes at run time
In .NET we have Reflection.Emit(C#) which can do that Reflection.Emit
Not sure whether there is a direct java equivalent. You can see another similar question on SO here Java equivalent of reflection.emit