Hi Ranchers -
To earn the OCA Java SE 8 Programmer I Certification, you should know your Java inside and out. One of best ways to do that is to write a lot of code.
Because a book can't cover all the possible code combinations on which you can be tested in the exam, I've included 'Twist in the Tale' exercises in my book.
Each chapter includes 4-6 such exercises. For these exercises, I’ve tried to use modified code from the examples already covered in the chapter. The Twist in the Tale title refers to modified or tweaked code. These exercises will help you understand how even small code modifications can change the behavior of your code. They should also encourage you to carefully examine all the code in the exam. The reason for these exercises is that in the exam, you may be asked more than one question that seems to require the same answer. But on closer inspection, you’ll realize that the questions differ slightly, and this will change the behavior of the code and the correct answer option!
To get you going, I've created an example for you to answer:
--------------------------------------
Twist in the Tale - Example 1
--------------------------------------
Given that the following example would concatenate and output the first and second command line parameters:
What happens, if you modify the preceding code to the following:
--------------------------------------
Twist in the Tale - End of Example 1
--------------------------------------
(Next example to follow in an hour.)
With much respect,
Mala
To earn the OCA Java SE 8 Programmer I Certification, you should know your Java inside and out. One of best ways to do that is to write a lot of code.
Because a book can't cover all the possible code combinations on which you can be tested in the exam, I've included 'Twist in the Tale' exercises in my book.
Each chapter includes 4-6 such exercises. For these exercises, I’ve tried to use modified code from the examples already covered in the chapter. The Twist in the Tale title refers to modified or tweaked code. These exercises will help you understand how even small code modifications can change the behavior of your code. They should also encourage you to carefully examine all the code in the exam. The reason for these exercises is that in the exam, you may be asked more than one question that seems to require the same answer. But on closer inspection, you’ll realize that the questions differ slightly, and this will change the behavior of the code and the correct answer option!
To get you going, I've created an example for you to answer:
--------------------------------------
Twist in the Tale - Example 1
--------------------------------------
Given that the following example would concatenate and output the first and second command line parameters:
What happens, if you modify the preceding code to the following:
--------------------------------------
Twist in the Tale - End of Example 1
--------------------------------------
(Next example to follow in an hour.)
With much respect,
Mala