Sun Education



Simulation test and Sun Education and Sample Questions and SCBCD 5.0 and 310-092

SCBCD Java upgrade free Practice Test at uCertify

uCertify will release the new PrepKit for SCBCD Java Upgrade Exam CX-310-092 on Feb 15, 2008. This PrepKit contains six practice tests to ensure your success in the SCBCD certification exam. There are 135 questions, including 105 quiz items, which will help you learn the key concepts as building blocks for understanding the complex concepts and technical terms. It also includes more than 80 study notes, including technical articles, how to’s and study tips covering all aspects that are essential for you to remember.

This exam tests your ability in designing, developing, deploying, and integrating Enterprise JavaBeans EJB Edition 3.0. If you are already certified with SCBCD (EJB 2.0), you can upgrade your certification to EJB 3.0 by qualifying the CX-310-092 exam.

If you pre order the PrepKit before the release date, you can get 50% discount on the regular price. Get the PrepKit CX-310-092 evaluation version with 30 free questions at uCertify.com.

Feb 09 2008 12:14 am | No Comments »


Quiz and Sun Education and SCDJWS and 310-220

Free Quiz for Exam CX-310-220 from Java.boot.by

Java.boot.by is offering SCDJWS free online quiz for Exam CX-310-220 (Sun Certified Developer for Java Web Services). The quiz questions available for this exam cover all the objectives separately.

The CX-310-220 exam tests your skills and competency in creating Web services applications using Java technology components that are included with Java Web Services Developer Pack and the J2EE 1.4 platform. This certification exam is helpful for you if you have experience in developing Web applications using the Java platform.

There are more than 95 quiz items with a detailed explanation of each question for you to understand the concepts clearly. Try this CX-310-220 quiz from the Web site.

Jan 05 2008 01:21 am | No Comments »


Sun Education and 310-019 and SCJA and Article

Article: Java-Data types, Variables, and Arrays

uCertify has sent us this article which is useful for the SCJA certification exam. The article helps you to understand the Java types, variables and arrays, a topic for CX310-019 exam.

Java-Data types, Variables, and Arrays
Java is a robust language. One of the factors, which makes Java robust is the fact that it is a strongly typed language, i.e., every variable has a type, every expression has a type, and every type is defined.Java defines eight primitive data types. These are as follows:
  1. int
  2. byte
  3. long
  4. short
  5. float
  6. char
  7. boolean
  8. double

These can be grouped into four main categories as listed below:

  • Integers: This includes int, long, short , and byte.
  • Floating-point numbers: This includes float and double. These represent numbers with fractional precision.
  • Characters: The char type is included in this category.
  • Boolean: The boolean is a special type to represent true/false values.

The width and range of each type is given below:

Type Width Range
byte 8-bit -128 to 127
short 16-bit -32,768 to 32,767
int 32-bit -2,147,483,648 to -2,147,483,647
long 64-bit -9,223,372,036,854,775,808 to 9,223,372,036,854,775,807
float 32-bit 1.4e-045 to 3.4e+038
double 64-bit 4.9e-324 to 1.8e+308
char 16-bit ‘\u0000′ to ‘\uffff ‘


Type Conversion and Type Casting

Java provides two kinds of data type conversions automatic and explicit. Automatic conversion takes place when the following two conditions are fulfilled:

  • The two types are compatible.
  • The destination type is larger than the source type.

When these two conditions are met, widening conversion takes place, i.e., a narrow data type is promoted to a wider one. For example, value of byte type will be promoted to int, as int is wider than byte in width.

In many cases automatic type conversions are helpful, but they fail to fulfill all the requirements. For example, an automatic conversion cannot be performed to convert int to byte, as int is wider than byte. The general form to perform such type of narrowing conversion is as follows:

(target-type) value

The example below describes an explicit conversion:

class Rat {
public static void main(String args[]){
int a=10,b=20;
byte c;
c= (byte)(a+b);
System.out.print(c);
}

}

here, the value obtained after adding variables a and b of int type is stored in c, which is of byte type. Therefore, before storing the value casting is done:

c= (byte)(a+b);

Variable

A variable is said to be a storage unit in Java. A variable is defined as the combination of an identifier, a type, and an optional initializer. Every variable has a scope, which defines its visibility, and a lifetime.

Variable Declaration:

The general form for declaring a variable in Java, is as follows:

type identifier[=value];

In the line mentioned above, type defines the data type of a variable. It can be int, short, char, etc. The identifier refers to the name of the variable, and the value is any constant assigned to a variable. The variable declaration must end with a semicolon “;”. Java keywords such as final, try, etc. are not allowed as variable names. Some examples given below describe variable declaration in detail:

int a, b, c; // declaration of three variables a, b, and c of int type.

int a=3, b; // declaration of two variables a and b and initialization of a.

char x=’x'; // declares char type variable and assigns value. The char type value must be within single quotes.

Dynamic Initialization of Variables :

The example given below describes the dynamic initialization:

class Dynamic {
public static void main(String args[]) {
int a=10, b=30;
double c=a+b; //dynamic initialization of variable c
System.out.print(c);
}
}

In the example given above, the variable c is dynamically assigned the value obtained after the addition of values stored in variables ‘a’ and ‘b’.

The Scope and Lifetime of a Variable

In the example mentioned above, all the variables are declared within the main method. However, Java allows a variable declaration within any block. An opening and closing brace defines a block. This is a block:

{

//block

}

A block defines a scope. A scope determines the visibility and lifetime of an object, which is defined inside it.

The other programming languages such as C defines two categories of scopes: global and local. These two traditional categories do not gel well with Java’s strict object-oriented model. In Java, the two main scopes are those that are defined by a class and a method.

The scope defined by a method begins with an opening brace and finishes with a closing brace. The parameters of a method are also within that scope.

As a rule, the variables declared inside a scope are only visible to the code within that scope. These variables are not visible to the code outside the scope. Therefore, declaring a variable inside a scope localizes it and prevents it from unauthorized access or modification.

Nested scopes are allowed, i.e., a scope within a scope. For example, each time a programmer creates a block of code, he creates a new, nested scope. When this happens, the outer scope encloses the inner scope. This means that objects declared in the outer scope will be visible to the code within the inner scope but not vice-versa. Objects declared inside the inner scope will not be visible to the outer scope.

The example below describes the nested scope:

class Nested {
public static void main(String args[]) {
int x; //visible to all code within main()
x=100;
if (x==100) { //start of new scope
int y=20; // known only within this block
//x and y both known here
System.out.println(+x + ” ” +y);
}

y=200; // error, as y is not known here
System.out.print(x) // x is known here
}
}

here, the variable x is declared at the start of the main() method’s scope and is accessible to all the subsequent code within the main method. The variable y is declared within the if block and is accessible within this block. That is why a compile-time error will be generated if y is initialized to 200.

Note : A variable is created when its scope is entered, and gets destroyed when its scope ends. This means that a variable will not hold its value once it has gone out of scope.

Array

An array is a group of variables of the same data type referred to by a common name. Arrays of any data type can be created and may have one or more dimensions. A particular element in an array is accessed by its index.

One Dimensional Array

A one-dimensional array is a list of variables of the same data type. The general form for creating a one-dimensional array is:

type var-name[]; or type[] var-name;

here, type refers to the data type of an array, and var-name refers to the name of the array.

For example,

int arr[];

This declares an empty array named arr of int type. In Java, the size of an array is set when it is explicitly created using the new operator.

int arr[]= new int [5];

It will create an array named arr of size 5. It will store 5 elements, from 0 to 4. The starting index of an array is 0.

The diagram below depicts a conceptual view of the array declared above:

here, each box will contain one element.

The first element of the array is positioned at the 0th location, therefore, to get the value of the first element, the following code is used:

System.out.print(arr[0]);

Note: In Java, the elements of an array are always set to default values after their creation. An int type array is set to 0 and a boolean type array contains false by default if no value is stored in an array.

Multidimensional Arrays

In Java, a multidimensional array is known as an array of arrays. The general form for declaring a multidimensional array:

type var-name[][]; or type[][] var-name;

like a one dimensional array, the size of a two dimensional array is also explicitly created using the new operator. The example below describes this:

int a[][]=new a[3][2];

This will create an array, which contains 3 rows and 2 columns. It will contain 3*2, i.e., 6 elements. The first index is [0][0] and the last index is [2][1]

Array size

In Java, the length field specifies the size of an array.

The example below describes its use.

class Rat {
public static void main(String args[]) {
int a[]=new int[4];
System.out.print(a.length);

here, the output will be 4.

What is an ArrayIndexOutOfBoundsException?

In Java, a run-time error ArrayIndexOutOfBoundsException is encountered when a program attempts to extract a value from an array outside its boundary. For example,

  1. class Rat {
  2. public static void main(String args[]) {
  3. int a[]=new int[4];
  4. System.out.print(a[5]);

The above-mentioned code will generate an exception at runtime, as the code at line number 3 declares and creates an array of size 4. It will have index starting from 0 to 3 , but the code at line number 4 attempts to extract the value from the 5th location.

Visit uCertify Web site to read more free articles for other Java certification exams.

Oct 31 2007 04:27 am | No Comments »


Online test and Sun Education and 310-055 and SCJP 5.0

Free Practice Test for SCJP 5 Exam 310-055 from Skillfox.com

Online training and practice test is a great way to prepare for your certification exams. Try the CX310-055 practice test available at Skillfox.com that comes with 50 questions. The SCJP 5 (Sun Certified Java Programmer 5) exam 310-055 is an entry-level exam for various Java certifications such as SCJD (Sun Certified Developer for the Java 2 Platform) and SCWCD (Sun Certified Web Component Developer for the J2EE Platform) certifications.

This exam measures your understanding and skills required in creating applications using the basic syntax and structure of the Java programming. The practice test covers only one objective i.e., Control Flow of the actual exam that will help you to clear your doubts in this area.

Register for CX310-055 practice test at Skillfox Web site and take the test now.

Oct 08 2007 04:58 am | No Comments »


Online test and Sun Education and SCSA and 310-014

Free Online Practice Test for SCSA Exam 310-014 from Testsworld.com

Testsworld.com offers a free online practice test containing 10 questions for Sun Certified System Administrator I (SCSA) for Solaris 9 certification exam 310-014. The Professionals who want to qualify this certification exam must have a minimum of six months working experience as a systems administrator. The exam measures your in-depth knowledge and competency of basic UNIX and Solaris Operating System (Solaris OS) commands.

The practice test for exam 310-014 is bundled with two test papers each comprising two modes of testing i.e., practice mode and test mode. There is an alternative to select the questions in a random or sequential order. The time allotted for the test is 20 minutes.

You can review the test with full explanations to the correct answer and also view your score obtained after each question. Choose any of these two test modes for 310-014 practice test at Testsworld.com at ensure your preparation for the exam.

Note: free registration is required.

Oct 04 2007 07:38 am | No Comments »

Next Page »