XYZ Technologies is a leading international provider of automated and IT enabled solutions catering to
businesses across various verticals around the globe. Since its inception in 1995, XYZ has regimented itself being
committed to deliver the best software solutions. XYZ has ever since used highly experienced resources in
analysis, development, quality assurance, and implementation to provide a wide range of high-quality consulting
services and cost-effective development of customized application software. XYZ’s worldwide domain and
subject matter expertise, proven track record and the capability to act as solution integrators can give you a truly
cost-effective solution that not only meets, but surpasses your needs.
XYZ –Recruitment For Win32 Programmers
XYZ wants to hire Win32 programmers for its new projects. The basic requirements required for a programmer
are given below:
• Bachelor’s in computer science/software engineering
• Have hands on knowledge of C/C++ language
• Have good knowledge about pointers and its different variations
The following set of questions is made for the applicants who will apply for this job. Now you as an
applicant need to solve the given questions:
A. Consider the following statements
long double i, *ptr;
ptr = &i;
When the above given statements are executed in the RAM 10 bytes of memory will be reserved.
Let’s suppose on each byte some information is stored but what you will do when you want to change only single a byte? Write the syntax to modify the byte no. 4 and 9 i.e. assign 25 to byte no. 4 and 45 to byte no. 9.
assign 25 to byte no. 4
assign 45 to byte no. 9
B. Write the total number of read and write operations against each statement, whereas num is integer array and ptr is integer pointer.
S.No. Statements Read Operation Write Operation
3 num= 67;
Read operations Write Operations
1 **ptr=4; 2 1
2 *(num+3); 0 1
3 num= 67; 0 1
4 ***ptr=100; 3 1
5 *(ptr+4)=8; ? ?
C. Convert the following array subscripts into indirection format:
Answer 1: *(p+7)
Answer ii : *(L+4) then *(*(L+4) +3)
Answer iii : *(M+1)  then *(*(M+1)+2) then *(*(*(M+1)+2)+3)
Answer iv : *(H+3)[i] then *(*(H+3) +i)
Answer v : *(X+1)  then *(*(X+1)+4) then *(*(*(X+1)+4)+2) then *(*(*(*(X+1)+4)+2)+3)
D. Read the following statements? (Reference: Concern Lecture No. 3 video lecture and slides for
complete understanding of concept).
a. char **array;
b. char *(*array)();
c. int *func(int);
d. float (*func)(float);
e. char *( *name)( char, char);
Lecture Covered: This Assignment covers Lecture No.1 – Lecture No. 4