Whizlabs offers SCJP 6.0 Exam Simulator with 420 questions as per the SCJP 6.0 certification exam. Following are couple of sample SCJP Dumps.
Topic: API Concepts
Question statement: Which of the following are true about the File class? Select two choices.
Choices:
Correct Anawer: C & D
Explaination:
Choices C and D are the correct answers. The exists() method of the File class returns true if the file given by the abstract path name physically exists. The delete() method can be used to delete the file represented by the File object. Choice A is incorrect because we cannot perform read/write operations on files using the File object. Choice B is incorrect because the File class does not define a size() method, it defines the length() method to find the size of a file. Reference: http://java.sun.com/j2se/1.5.0/docs/api/java/io/File.html
Topic: OO Concerpts
Question statement: Which of the following is true about the takeOrdersAndServe() method in the below code?
class Waitor
{
void takeOrders(){}
void serveFood(){}
void takeOrdersAndServe()
{
takeOrders();
serveFood();
}
}
Choices:
Correct Anawer: B
Explaination:
Choice B is the correct answer.
Cohesion refers to the number and diversity of tasks that a single unit is responsible for. If each unit is responsible for one single logical task, we say it has high cohesion.
Cohesion applies to classes and methods. Here the takeOrdersAndServe() method is not focused on a single task, so it shows low cohesion. A well designed unit will have high cohesion.
More about coupling, cohesion and other related concepts here.
http://satc.gsfc.nasa.gov/support/STC_APR98/apply_oo/apply_oo.html
|
|
|
| What's Next? | |
![]() |
You can try out our 15 Questions Trial Test for FREE. Till now more than 19,000 participants have appeared in the trial exam . Try out the test and assess your rank compare to other test takers. This will help you to assess your strengths, weaknesses, speed and accuracy level in each Objective of SCJP 6 Certification Exam. |
Sending your message. Please wait...
Thanks for sending your message! We will get back to you shortly.
There was a problem sending your message. Please try again.
Please complete all the fields in the form before sending.