Placement Papers - HP

HP Placement Paper Pattern III
Posted by :
Nikhil Kulkarni
(18)
HP Paper Pattern
There Were 3 Sections:
PART- 1 ( 40 Q s (Fundamental Computer Concepts, Includes OS, N/w , Protocols )
PART-2 ( 20 Q s (Purely C ) -- Bit tricky (Involves ADA Concepts )
PART-3 ( 20 Q s (Analytical) -- Very Easy )
I don\' t remember all the Qs. however some of them which i do have been written below.
They are not in order or part of .
Q : What is not a part of OS ?
Op. : swapper, compiler, device driver, file system.
A : compiler.
Q : what is the condition called when the CPU is busy swapping in and out pages of memory without doing any useful work ?
Op. Dining philosopher s problem, thrashing, race around, option d
A: thrashing.
Q : How are the pages got into main memory from secondary memory?
DMA, Interrupts,option3, option 4
A : as far as i know its Interrupts --by raising a page fault exception.
Q : What is the use of Indexing ?
Op. fast linear access, fast random access, sorting of records , option 4
A : find out....
Q : in terms of both space and time which sorting is effecient.(The question is rephrased .)
Op. merge sort, bubble sort, quick sort, option 4
A : find out
Which case statement will be executed in the following code ?
main()
{
int i =1;
switch(i)
{
i++;
case 1 : printf ("");
break;
case 2 : printf("");
break;
default : printf("");
break;
}
}
Answer : Case1 will only be executed.
Q : In the given structure how do you initialize the day feild?
struct time {
char * day ;
int * mon ;
int * year ;
} * times;
Options : *(times).day, *(times-.day), *times-.*day.
Answer : *(times-.day) -- after the execution of this statement compiler generates error.i didn t understand why.can anybody explain.
Q: The char has 1 byte boundary , short has 2 byte boundary, int has 4 byte boundary. What is the total no. of bytes consumed by the following structure:
struct st {
char a ;
char b;
short c ;
int z[2] ;
char d ;
short f;
int q ;
}
Options are given.
Answer : its very easy 20 and not 19 .
There Were 3 Sections:
PART- 1 ( 40 Q s (Fundamental Computer Concepts, Includes OS, N/w , Protocols )
PART-2 ( 20 Q s (Purely C ) -- Bit tricky (Involves ADA Concepts )
PART-3 ( 20 Q s (Analytical) -- Very Easy )
I don\' t remember all the Qs. however some of them which i do have been written below.
They are not in order or part of .
Q : What is not a part of OS ?
Op. : swapper, compiler, device driver, file system.
A : compiler.
Q : what is the condition called when the CPU is busy swapping in and out pages of memory without doing any useful work ?
Op. Dining philosopher s problem, thrashing, race around, option d
A: thrashing.
Q : How are the pages got into main memory from secondary memory?
DMA, Interrupts,option3, option 4
A : as far as i know its Interrupts --by raising a page fault exception.
Q : What is the use of Indexing ?
Op. fast linear access, fast random access, sorting of records , option 4
A : find out....
Q : in terms of both space and time which sorting is effecient.(The question is rephrased .)
Op. merge sort, bubble sort, quick sort, option 4
A : find out
Which case statement will be executed in the following code ?
main()
{
int i =1;
switch(i)
{
i++;
case 1 : printf ("");
break;
case 2 : printf("");
break;
default : printf("");
break;
}
}
Answer : Case1 will only be executed.
Q : In the given structure how do you initialize the day feild?
struct time {
char * day ;
int * mon ;
int * year ;
} * times;
Options : *(times).day, *(times-.day), *times-.*day.
Answer : *(times-.day) -- after the execution of this statement compiler generates error.i didn t understand why.can anybody explain.
Q: The char has 1 byte boundary , short has 2 byte boundary, int has 4 byte boundary. What is the total no. of bytes consumed by the following structure:
struct st {
char a ;
char b;
short c ;
int z[2] ;
char d ;
short f;
int q ;
}
Options are given.
Answer : its very easy 20 and not 19 .
Quick links
Quantitative Aptitude
Verbal (English)
Reasoning
Programming
Interview
Placement Papers