Wednesday, 30 November 2011

"HCL" Recruiting: BE/BTech/ME/MTech/MCA/BCA 2011 Freshers @ All over India

Company        HCL
Website          www.hcl.in
Eligibility      BE/BTech/ME/MTech/MCA/BSC/BCA

Experience     Freshers

Location         All over india
HCL
Job Role: Freshers-2011 Passouts
Candiates Should Have:

Candiates Should be BE/Btech/ME/Mtech/MCA in CS,Electronics,Electrical,IT,IS.

BSC in CS,Maths,Electronics,Statics and IT

BCA and Diploma holders are also eligible.

Should have 65% in 10th,12th,Degree,PG with no back logs.

Should be 2011 passout


Click Here to apply 

Drag & Drop Questions for SCJP


1) Place code into the class so that it compiles & generates the out put answer=42. Note:
Code options may be used more than once.
     Class
      public class Place here        {
           
              private Place here object;
              public Place here(Place here object){
                         this.object = object;
             }
           
               public Place here getObject() {
                       return object;
                }
      }
               public static void main(String[] args) {
               
                   Gen<String> str = new Gen<String>(“answer”);
                   Gen<Integer> intg = new Gen<Integer>(42);
                   System.out.println(str.getObject() + “=” + intg.getObject());
               }
      }
Code Options
Gen<T>
Gen<?>
Gen
?
T


Solution:-
      public class Gen<T>       {
           
              private T object;
              public Gen(T object){
                         this.object = object;
             }
           
               public T getObject() {
                       return object;
                }
      }
               public static void main(String[] args) {
               
                   Gen<String> str = new Gen<String>(“answer”);
                   Gen<Integer> intg = new Gen<Integer>(42);
                   System.out.println(str.getObject() + “=” + intg.getObject());
               }
      }



2) Given:
public void takeList(List<? extends String> list) {
       // insert code here
}
Place the compilation results on each code statement to indicate whether or not
that code will compile if inserted into the takeList() method.


Code Statements                                     Compilation Result
---------------------------------------------------------------------
List.add(“Foo”);                                      Compilation Fails
List = new ArrayList<String>();               Compilation Succeeds
List = new ArrayL:ist<Object>();            Compilation Fails
String s = list.get(0);                                Compilation Succeeds
Object o = list                                         Compilation Succeeds


3) Place the correct description of the compiler output on the code fragments to be
inserted at liens 4 and 5. The same compiler output may be used more than once.
import java.util.*;
public class X {
      public static void main(String[] args){
           // insert code here
           // insert code here
      }
      public static void foo(List<Object> list) {}
}
Code
a) ArrayList<String> x1 = new ArrayList<String>();
    foo(x1);
b) ArrayList<Object> x2 = new ArrayList<String>();
     foo(x2);
c) ArrayList<Object> x3 = new ArrayList<Object>();
    foo(x3);
d) ArrayList  x4 = new ArrayList ();
     foo(x4);
Compiler Output
1) Compilation succeeds
2) Compilation fails due to an error in the first statement
3) Compilation of the first statement succeeds, but compilation fails due to error
in the second statement.
Solution:-
a = 3
b = 2
c = 1
d = 1



4) Place the output option in the actual output sequence to indicate the output
from this code.
class Alpha {
      public void foo(String… args)
         { System.out.println(“Alpha:foo”);}
      public void bar(String a)
         { System.out.println(“Alpha:bar”);}
}
public class Beta extends Alpha {
     public void foo(String a)
         { System.out.println(“Beta:foo”);}
      public void bar(String a)
         { System.out.println(“Beta:bar”);}
      public static void main(String[] argv){
            Alpha a = new Beta();
            Beta b = (Beta)a;
           
            a.foo(“test”);    b.foo(“test”);
            a.bar(“test”);     b.bar(“test”);
      }
}
Actual output sequence
1)              2)             3)              4)
Output options
Alpha:foo                Alpha:bar            Beta:foo            Beta:bar
Solution:-
1) Alpha:foo   2) Beta:foo  3) Beta:bar    4) Beta:ba


5) Place the lines in the correct order to complete the enum.
enum Element {
1st
2nd
3rd
4th
5th
}
Lines
public string info() {return “element”;}
};
FIRE { public string info() {return “Hot”;}
EARTH, WIND,
}
Solution
EARTH, WIND,
FIRE { public string info() {return “Hot”;}
};
public string info() {return “element”;}
}


6) Place the code elements in order so that the resulting java sources file will
compile correctly, resulting in a class called com.sun.cert.AddressBook.
Source file
1st
2nd
3rd
ArrayList entries;
}
Code Element
package com.sun,cert;
package com.sun,cert.*;
import java.util.*;
import java.*;
public class AddressBook {
public static class AddressBook{
Solution: -
package com.sun,cert;
import java.util.*;
public class AddressBook {
ArrayList entries;
}



7) Place the code fragment in position to complete the displayable interface.
interface Reloadable {
public void reload();
}
interface diplayable place here place here {
place here
}
Code Fragments:
extends public void display(); Reloadable
implements public void display() {/*Display*/} Edit
Solution:-
interface Reloadable {
public void reload();
}
interface diplayable extends Reloadable {
public void display();
}
8) Place the correct code in the code sample to achieve the expected results:
Expected Results:-
Output: 1 2 4 8 16 32
Code Sample:-
int [] y = { 1, 2, 4, 8, 16, 32};
System.out.print (“Output: ”);
Place here
System.out.prinr (x);
System.out.print(“ “);
}

Code:-
1) for(int x : y) {
2) for(int x = y[ ]){
3) foreach(y as x) {
4) foreach(int x : y) {
5) for (int x=1; x=y[ ]; x++){
Solution:-
int [] y = { 1, 2, 4, 8, 16, 32};
System.out.print (“Output: ”);
for(int x : y){
System.out.prinr (x);
System.out.print(“ “);
}
9) Chain these constructors to create objects to read from a file named “in” and to
write to a file named “out”.
reader = place here place here”in” ));
writer= place here place here place here”out” )));
Constructor
new FileReader( new PrintReader( new BufferedReader(
new BufferedReader( new FileWrite( new PrintWriter(
Solution:-
reader = new BufferedReader(new FileReader(“in”));
writer = new PrintWriter(new BufferedWriter(new FIleWriter(“out”)));

Place the code fragments into position to use a BufferedReader to read in an entire
text file:
class PrintFile {
public static void main(String[] args){
BufferedReader buffReader = null;
//More code here to initialize buffReader
try{
String temp;
while ( place here place here ) {
System.out.printin(temp);
}
} catch place here
e.printStackTrace();
}
}
}
Code Fragments
(temp = buffReader.readLine() ) && buffReader.hasNext()
(temp = buffReader.nextLine()) (IOException e) {
!= null (FileNotFoundException e){
Solution:-
class PrintFile {
public static void main(String[] args){
BufferedReader buffReader = null;
//More code here to initialize buffReader
try{
String temp;
while ((temp = buffReader.readLine() ) != null ) {
System.out.printin(temp);
}
} catch (IOException e) {
e.printStackTrace();
}
}
}

10) Given:
class A {
String name = “A”;
String getName() {
return name;
}
String greeting(){
return “class A”;
}
}
class B extends A {
String name = “B”;
String greeting(){
return “class B”;
}
}
public class Client {
public static void main(String[] args) {
A a = new A();
A b = new B();
System.out.println(a.greeting() + “ has name ” + a.getName());
System.out.println(b.greeting() + “ has name ” + b.getName());
}
}
Place the names “A” and “B” in the following output:
class place here has name place here
class place here has name place here
Names
A B
Solution:-
class A has name A
class B has name A










Tuesday, 8 November 2011

Eclipse Shortcuts


Navigational Shortcuts



F10Main menu
Shift F10
Context menu
Ctrl F10
View menu


Work space navigation



F12
Activate editor
Ctrl+Shift+W
Switch editor
Ctrl F6
Next editor
Ctrl Shift F6
Prev editor
Ctrl F7
Next workspace
Ctrl Shift F7
Prev workspace
Ctrl F8
Next perspective
Ctrl Shift F8
Prev perspective
Alt Left
Back
Alt Right
Forward


Files



Alt Shift S
Show in…
Ctrl Shift R
Jump to file
Ctrl N
New file
Ctrl S
Save file
Ctrl Shift S
Save all files
Ctrl F4
Close file
Ctrl Shift F4
Close all files

Find



Ctrl L
Goto line
Ctrl F
Find
Ctrl J
Incremental find
Ctrl Shift J
Incremental find prev
Ctrl K
Find next
Ctrl Shift K
Find prev
Ctrl H
Search workspace
Ctrl (dot)
Navigate next
Ctrl (comma)
Navigate prev


Java navigation
F3
Goto declaration
Ctrl Shift U
Find references in file
Ctrl Shift G
Find references in workspace
Ctrl G
Find declarations in workspace
Ctrl Shift P
Navigate to matching bracket/brace
Ctrl T
Popup type hierarchy
Ctrl Shift T
Open Type
Ctrl O
Outline of current source
Ctrl F3
Outline of current cursor position
Ctrl Shift Arrow
Jump beetween methods up or down
F2
Show Javadoc
F4
Show hierarchy
Ctrl Alt H
Open call hierarchy


General editing



Alt Arrow
Move line(s) up or down
Alt Shift Up
Expand selection to enclosing element
Alt Shift Right
Expand selection to next element
Alt Shift Left
Expand selection to previous element
Alt Shift Down
Restore previous selection
Ctrl Alt Arrow
Duplicate line(s) up or down
Shift Enter
Insert line below
Ctrl Shift Enter
Insert line above
Ctrl D
Delete line
Ctrl Shift Q
Toggle Quick Diff
Ctrl Shift Y
Convert to lowercase
Ctrl Shift X
Convert to uppercase


Java editing



Alt Shift U
Remove occurrence annotations
Ctrl 1
Quick fix (works even when there are no errors
Ctrl Shift M
Add import
Ctrl Shift F
Reformat
Ctrl Shift O
Organize Imports
Ctrl /
Comment
Ctrl \
UnComment
Ctrl Shift Space
Parameter hints
Ctrl
Hyperlink identifier
Ctrl I
Correct indentation
Shift Space
Incremental content assist


Debugger



F5
Step into
F6
Step over
F7
Run to return
F8
Resume
F9
Relaunch last
F11
Run/debug last
Ctrl F11
Run
Ctrl Shift B
Toggle breakpoint
Ctrl D
Display
Ctrl Q
Inspect
Ctrl R
Run to line
Ctrl U
Run snippet


Refactoring



Alt T
Refactoring menu
Ctrl Shift Z
Undo refactor
Ctrl Shift Y
Redo refactor
Alt Shift R
Rename
Alt Shift V
Move
Alt Shift I
Inline
Alt Shift M
Extract method
Alt Shift L
Extract local
Alt Shift C
Change method signature


Misc



F5
Refresh
F1
Infopop
F2
Show resizeable hover

Wednesday, 2 November 2011

HCL Referal Walk-in event details:

Experience/Work Location  :  4 to 8 years -Bangalore

Required Skills
·         Java J2EE: Tech Leads
·         Core Java/Swing: Senior Developer, Technical Leads
·         Java/J2EE with App server- Weblogic: Senior Developer, Technical Leads
·          C++ Unix – Application Development: Senior Developer, Technical Leads

Walk-in venue, date and time
HCL Technologies Ltd.
The Senate, #33/1, Ulsoor Road,
Bangalore – 560042.
Ph: 080-41906000
Landmark: Turn right after the junction near Manipal Center – MG Road.

Saturday, November 5, 2011.
9:30 AM to 12 PM
-----------------------------------------------------------------------------------------------------
Experience/Work Location  :  3 to 7 years - Chennai

Required Skills

·         C/C++ Developers with Video Streaming Application Development
·          Linux Kernel Development (C++/C Redhat)

Walk-in venue, date and time :

HCL Technologies Ltd.
8 & 9, GB Palya, Off Hosur Road, Bangalore – 560068. Near RNS Motors

HCL Technologies Ltd.
184, Arcot Road, Vadapalani, Chennai – 600026. Opposite Vasan Eye Care.

HCL Technologies Ltd.
Special Economic Zone,
L&T Phoenix Info Park Pvt. Ltd
Building: H-08; Level-2 & 3, HITEC CITY 2 -Survey No.30, 34, 35 and 38
Hyderabad-500 081

Sunday, November 6, 2011.
9:30 AM to 3 PM

---------------------------------------------------------------------------------------------------------------------------------
Experience/Work Location  :  4 to 7 years - Chennai

Required Skills

J2EE (SSE)

Walk-in venue, date and time

HCL Technologies Ltd.
Arihant Technopolis, #4/293, Old Mahabalipuram. Road, Kandanchavadi, Chennai- 600096.
Landmark: Next to Krishna Tennis Court.

Saturday, November 5, 2011.
10 AM to 2 PM

---------------------------------------------------------------------------------------------------------------------------------
 
Related Posts Plugin for WordPress, Blogger...