Take one example, Class A a{ } interface B Class C c{ } when we compile this how many classes will give the output?
NOTE : [I][This question was asked by Srivani][/I]
Printable View
Take one example, Class A a{ } interface B Class C c{ } when we compile this how many classes will give the output?
NOTE : [I][This question was asked by Srivani][/I]
The question is you asked is not clear.. just tell me i think you have 2 class and one interface..is it right or not and ask the question in right manner now......
then you will be having 2 classes:confused:
u will hv 3 class files created.. but u will hv a 2 classes and one interface from java point of veiw.. as interface is also a ttype of class jst its behaves differently...
2 classes i think...
if a program contains 2 classes and one interface then after Compilation how many class files will be generated? is it Ur Question?
if it so, Three class files will be generated.
the out put classes or two only.....coz.. a in dynamically override to interface memeber funs,and C , so two classes only produce the out put.iam right!
Three classes will be created because interface is also a class.