Ask Google

Custom Search
Showing posts with label Ask Java. Show all posts
Showing posts with label Ask Java. Show all posts

Tuesday, February 22, 2011

Ask Java 6


Today i will cover simple and basic question if someone ask you what is java.
The first things you need to know regarding java is Object Oriented Programming or in
short OOP.So What is OOP?

What is OOPs?

So your answer when people ask you this questions, what you will do is
you just rilex and explain to them OOP is programming whereby you
organizes your program in well defined interfaces to the data in object.Means
everything is in object.Nothing more.We can say object oriented as how we access
the data through object or in other word data controlling to code.



Blogging

Monday, February 21, 2011

Ask Java 5

Topic for today we will cover simple basic question regarding access right.
Lets say if main method we declared it as private?What will happen?

Explaination:
When main method is declared as private, it will shows you
message says "Main method not public" during runtime.Of course it will
compile properly.


Blogging

Sunday, February 20, 2011

Ask Java 4

Today i will cover one more question here..simple yet basic

What is mutual exclusion? How can you take care of mutual exclusion using Java threads?



Java provides many utilities to deal with mutual exclusion with the use of threaded programming.
Mutual exclusion is where no two processes can access critical regions of memory at the same time.

For mutual exclusion, you can simply use the synchronized keyword and explicitly or implicitly provide an Object, any Object, to synchronize on.

The runtime system/Java compiler takes care of the gruesome details for you. The synchronized keyword can be applied to a class, to a method, or to a block of code. There are several methods in Java used for communicating mutually exclusive threads such as wait( ), notify( ), or notifyAll( ). For example, the notifyAll( ) method wakes up all threads that are in the wait list of an object.


Blogging

Saturday, February 19, 2011

Ask Java 3

What is a cartesian product in PL/SQL?

 When a Join condition is not specified by the programmer or is invalid(fails), PL/SQL forms a Cartesian product.

In a Cartesian product, all combinations of rows will be displayed.

For example, All rows in the first table are joined to all rows in the second table. It joins a bunch of rows and it's result is rarely useful unless you have a need to combine all rows from all tables. 


Blogging

5L15K

  © Blogger template The Beach by Ourblogtemplates.com 2009

Back to TOP