Answer Posted / sathish.pk
java is not pure object oriented .
because, we are using "Static" keyword.
for example:
-------------
public class Sample{
public static void add(){
int a=1,b=2;
System.out.println("Add Value="+(a+b));
}
public void sub(){
int a=1,b=2;
System.out.println("Sub value="+(b-a));
}
public static void main(String args[]){
Sample sam=new Sample();
sam.sub();
Sample.add();
}
}
in above example:
------------------
we are creating object for access add() method, but
we are not creating object for access sub() method. because,
it is static method. so, here we are accessing add() method
without creating object. that all...
so, java is not pure object oriented ..
| Is This Answer Correct ? | 0 Yes | 2 No |
Post New Answer View All Answers
What is jdbc connection?
Does jdbctemplate close connection?
What is the significance of DataBaseMetaData.tableIndexStatistics? How to obtain and use it?
What is savepoint in jdbc?
Does jdbc require oracle client?
Explain Basic Steps in Writing a Java Program Using Jdbc?
What is the return type of class.forname() method?
Is possible to open a connection to a database with exclusive mode with JDBC?
Where jdbc drivermanager class is used?
What is jdbc odbc?
What is jdbc type?
Describe the steps needed to execute a sql query using jdbc.
How do I start debugging problems related to the JDBC API?
Why do we need jdbc?
What are common JDBC Exceptions?