Filter
Oil India Limited Placement Papers Ramco Placement Papers Rockwell Placement Papers3i Placement PapersABB Placement PapersAccel Frontline Placement PapersAccenture Placement PapersAcumen Software Placement PapersAditi Placement PapersAdobe Placement PapersADP Placement PapersAgile Placement PapersAgreeya Placement PapersAIG Placement PapersAkamai Placement PapersAks Software Systems Placement PapersAlcatel Placement PapersAllahabad Placement PapersAlle Placement PapersALLFON Placement PapersAlter Placement PapersAlumnus Placement PapersAmdocs Placement PapersAMI Placement PapersAndhra Bank Placement PapersANZ Placement PapersAppLabs Placement PapersAricent Placement PapersASDC Placement PapersAshok Placement PapersAshok LeyLand Placement PapersAspire Placement PapersASPNET Placement PapersAST Pvt Ltd Placement PapersAsto Placement PapersAtlas Placement PapersAxentis Soft Placement PapersAxes Placement PapersAztec Placement PapersBAAN Placement PapersBajaj Placement PapersBank Of Maharashtra Placement PapersBARC Placement PapersBEL Placement PapersBEML Placement PapersBently Placement PapersBFL Placement PapersBHEL Placement PapersBirlasoft Placement PapersBlueStar Placement PapersBOB Placement PapersBOSCH Placement PapersBPL Placement PapersBrakes Placement PapersBSNL Placement PapersC-DOT Placement PapersCadence Placement PapersCalsoft Placement PapersCampaq Placement PapersCanarys Placement PapersCapgemini Placement PapersCaritor Placement PapersCarrizalsoft Technologies Placement PapersCarrizalsoft Technologies Pvt Ltd Placement PapersCaterpillar Placement PapersCD Placement PapersCDAC Placement PapersCelstream Placement PapersCGI Placement PapersChangepond Placement PapersChatargee Placement PapersCisco Placement PapersCiticorp Placement PapersCMC Placement PapersCOGNIZENT Placement PapersComputer Placement PapersConsagous Placement PapersConsagous Technologies Placement PapersConvergys Placement PapersCORDYS Placement PapersCOSL Placement PapersCovansys Placement PapersCrompton Placement PapersCSC Placement PapersCTS Placement PapersDaimler Placement PapersDell Placement PapersDeloitte Placement PapersDelphi-tvs Placement PapersDeutsche Placement PapersDharma Placement PapersDigital Placement PapersdMtechnologies Placement PapersDot Placement PapersDot Com Infoway Placement PapersDRDO Placement PapersDSL Placement PapersDSQ Placement PapersDSRC Placement PapersE2E Placement PapersEasyTech Placement PapersEDS Placement PapersEFFIGENT Placement Papersefunds Placement PapersEIL Placement PapersELGI Placement PapersELICO Placement PapersEnercon Placement PapersEpson Placement PapersEricssion Placement PapersEssar Placement PapersFCG Placement PapersFidelity Placement PapersFlextronics Placement PapersForbes Placement PapersFORCE Placement PapersFuture Placement PapersFX Placement PapersFX Labs Placement PapersG2One Network Private Limited Placement PapersGDA Placement PapersGE Placement PapersGenpact Placement PapersGeodesic Placement PapersGeometric Placement PapersGlobal Placement PapersGodrej Placement PapersGoogle Placement PapersGrapcity Placement PapersGSSL Placement PapersHAL Placement PapersHCL Placement PapersHCL Technologies Placement PapersHello Placement PapersHexaware Placement PapersHFCL Placement PapersHindustan Placement PapersHo Placement PapersHoneywell Placement PapersHorizon Placement PapersHP Placement PapersHPCL Placement PapersHSBC Placement PapersHuawei Placement PapersHughes Placement PapersI-Flex Placement PapersI-Gate Placement Papersi2 Placement PapersIBM Placement PapersIBPS Placement PapersIBS Placement PapersICICI PO DRIVE Placement PapersIDBI Placement PapersIikanos Placement PapersIindus Placement PapersIkosindia Placement PapersImpetus Placement Papersinautix Placement PapersIndian Overseas Bank Placement PapersIndusTeqsite Placement PapersInfineon Placement PapersInformatica Placement PapersInfosys Placement Papersinfotech Placement PapersInphlox Placement PapersIntec Placement PapersIntegra Placement PapersIntegraphr Placement PapersInterwoven Placement PapersIntex Placement PapersIOCL Placement PapersIonnor Solutions Placement PapersiSoft Placement PapersIspat Placement PapersISRO Placement PapersIttiam Placement PapersIvega Placement PapersJ&B Placement PapersJataayu Placement PapersJean Placement PapersJean Martin Placement PapersJet Placement PapersJEYPEE Placement PapersJindal Placement PapersJKT Placement PapersJOHN Placement PapersKalam Software Technology Placement PapersKanbay Placement PapersKeane Placement PapersKenexa Placement PapersKkshema Placement PapersKleward Placement PapersKnoah Solutions Placement PapersKPIT Placement PapersKPIT Cummins Placement PapersL&T Placement PapersL&T Infotech Placement PapersL&T(EEC) Placement PapersLCube Placement PapersLG Placement PapersLG Soft India Placement PapersLifetree Placement PapersLinkwell Placement PapersLionBridge Placement PapersLogica Placement PapersLucent Placement PapersM-Phasis Placement PapersMA Placement PapersMANGANESE Placement PapersMascot Placement PapersMastek Placement PapersMatrix Placement PapersMAXSOFT Placement PapersMcAfee Placement PapersMECON Placement PapersMentor Placement PapersMerrill Placement PapersMicrosoft Placement PapersMindfire Solutions Placement PapersMindtree Placement PapersMiraclesoft Placement PapersMistral Placement PapersMotorola Placement PapersMTNL Placement PapersNagarro Placement PapersNalko Placement PapersNCR Placement PapersNess Placement PapersNest Placement PapersNewgen Placement PapersNFL Placement PapersNHPC Placement PapersNihilent Placement PapersNIIT Placement PapersNovartis Placement PapersNovell Placement PapersNTPC Placement PapersNucleus Placement PapersNYROS TECHNOLOGY Placement PapersOil Placement PapersONGC Placement PapersOnline Education Placement PapersOnMobile Placement PapersOracle Placement PapersOrange Placement PapersParagon Placement PapersPCS Placement PapersPDIL Placement PapersPentaware Placement PapersPentaware Tech Placement PapersPerot Placement PapersPersistent Placement PapersPhilips Placement PapersPlanetasia Placement PapersPNESTEC Placement PapersPolaris Placement PapersPoor Placement PapersPramati Placement PapersProdEx Placement PapersPSI Placement PapersQuark Placement PapersQuinnox Placement PapersQwest Placement PapersR Placement PapersRamco Placement PapersRapidigm Placement PapersRBI Placement PapersRedpine Placement PapersReliance Placement PapersReliance(RIL) Placement PapersRinl Placement PapersRipples Infolink Placement PapersRobert Placement PapersRobert Bosch Placement PapersRockwell Placement PapersRRB(Railway Placement PapersRRB(Railway Recruitment Board ) Placement PapersRSsoftware Placement PapersSahi Placement PapersSail Placement PapersSamsung Placement PapersSamtel Placement PapersSAP Placement PapersSapient Placement PapersSasken Placement PapersSatyam Placement PapersSBI Placement PapersScandent Placement PapersSchneider Placement PapersSCT Placement PapersSemanticSpace Placement PapersShriram Placement PapersSIEMENS Placement PapersSierra Placement PapersSkyTECH Placement PapersSLK Software Placement Paperssobha Placement PapersSoftSol Placement PapersSonata Placement PapersSony India Placement PapersSQL Placement PapersSQL Star Placement PapersSSC Placement PapersStarent Placement PapersStarent Networks Placement PapersSTMicroelectronics Placement PapersSubex Placement PapersSUN Placement PapersSuther Placement PapersSynergy Placement PapersSynopsys Placement PapersSyntel Placement PapersSystech Solutions Placement PapersTalisma Placement PapersTata Placement PapersTata Technologies Placement PapersTavant Placement PapersTCE Placement PapersTCS Placement PapersTech Placement PapersTech Mahindra Placement PapersTELCO Placement PapersTelserra Placement PapersTEMNOS Placement PapersTesco Placement PapersTexas Placement PapersThermax Placement PapersThink Placement PapersTHOROGOOD Placement PapersThoughtWorks Placement PapersTIL Placement PapersTISL Placement Paperstorry Placement PapersTriad Placement PapersTriam Placement PapersTrianz Placement PapersTrilogy Placement PapersTSPL Placement PapersTVS Placement PapersUbiNetics Placement PapersUnited Placement PapersUnited Health Group Placement PapersUS Placement PapersValueLabs Placement PapersValueOne Placement PapersVariFone Placement PapersVedanta Placement PapersVerchaska Placement PapersVERITAS Placement PapersVerizon Placement PapersVernalis Placement PapersVirtusa Placement PapersVisual Placement PapersVIT Placement PapersVizag Steel Plant Placement PapersVizual Placement PapersVSNL Placement PapersVsworx Placement PapersWBPDCL Placement PapersWepIndia Placement PapersWilco Placement PapersWipro Placement PapersXansa Placement PapersXcino Placement PapersYahoo Placement PapersYantro Placement PapersYASH Placement PapersZenith Placement PapersZenser Placement PapersZTE Placement Papers

Download mistral Placement Papers in MS Word and PDF Format for Job Interview

List of all download mistral placement papers in ms word and pdf format for job interview. Click Here View Job List. This page will help you to get all details about download mistral placement papers in ms word and pdf format for job interview. Download mistral placement papers in PDF and Ms word format. Latest and mistral last 5 years placement papers with solutions pdf download for campus job.

Mistral Placement Paper : General - Interview DRK College Of Technology - 5 October 2007

MISTRIAL PAPER ON 5th OCTOBER 2007

Hi
Every body this is B.Pavan of Aurora. We had interHview of minvesta company on october 5th 2007 in DRK college. Well the interview was quiet easy and consists of three sections.The duration of the test is 1 hour.
Coming to 1st section.It consists of 10 questionns. This section consists of all theory questions. Friends try to answer them in one line.

I had questions like following:-
1. What is the difference between a class and object?
2. What is stored procedure? What are its advantages and disavantages?
3. Which is better trigger or stored procedure?
4. What is difference between data set and data reader?(.net)
5. Write a querry for accesing unique rows from emp(Ename,Age) sorted by age?
6. What is the difference between Function overloading, Function Overriding and Virtual Functions?
7. Difference between multiple and multilevel inheritence?
8. Differnce between interfaces and abstract classes?

Sorry i don,t remember remaining two. Like this he is concerntarting on OOPs, DBMS, .NET

Mistral Placement Paper : Technical - C & C++

Mistral Solutions

C Section

1. What does the following program print?
#include
int sum,count;
void main(void)
{< BR> for(count=5;sum+=--count;)
printf("%d",sum);
}
a. The pgm goes to an infinite loop b. Prints 4791010974 c. Prints 4791001974
d. Prints 5802112085 e. Not sure

2. What is the output of the following program?
#include
void main(void)
{
int i;< BR> for(i=2;i<=7;i++)
printf("%5d",fno());
}
fno()
{
staticintf1=1,f2=1,f3;
return(f3=f1+f2,f1=f2,f2=f3);
}
a. produce syntax errors b. 2 3 5 8 13 21 will be displayed c. 2 2 2 2 2 2 will be displayed
d. none of the above e. Not sure

3. What is the output of the following program?
#include
void main (void)
{
int x = 0x1234;
int y = 0x5678;
x = x & 0x5678;
y = y | 0x1234;
x = x^y;
printf("%x\t",x);
x = x | 0x5678;
y = y & 0x1234;
y = y^x;
printf("%x\t",y);
}
a. bbb3 bbb7 b. bbb7 bbb3 c. 444c 4448
d. 4448 444c e. Not sure

4. What does the following program print?
#include
void main (void)
{
int x;
x = 0;
if (x=0)
printf ("Value of x is 0");
else
printf ("Value of x is not 0");
}
a. print value of x is 0 b. print value of x is not 0 c. does not print anything on the screen
d. there is a syntax error in the if statement e. Not sure

5. What is the output of the following program?
#include
#include
int foo(char *);
void main (void)
{
char arr[100] = {"Welcome to Mistral"};
foo (arr);
}
foo (char *x)
{
printf ("%d\t",strlen (x));
printf ("%d\t",sizeof(x));
return0;
}
a. 100 100 b. 18 100 c. 18 18 d. 18 2 e. Not sure

6. What is the output of the following program?
#include
display()
{
printf ("\n Hello World");
return 0;
}
void main (void)
{
int (* func_ptr) ();
func_ptr = display;
printf ("\n %u",func_ptr);
(* func_ptr) ();
}
a. it prints the address of the function display and prints Hello World on the screen
b. it prints Hello World two times on the screen
c. it prints only the address of the fuction display on the screen
d. there is an error in the program e. Not sure

7. What is the output of the following program?
#include
void main (void)
{
int i = 0;
char ch = ,A,;
do
putchar (ch);
while(i++ < 5 || ++ch <= ,F,);
}
a. ABCDEF will be displayed b. AAAAAABCDEF will displayed
c. character ,A, will be displayed infinitely d. none e. Not sure

8. What is the output of the following program?
#include
#define sum (a,b,c) a+b+c
#define avg (a,b,c) sum(a,b,c)/3
#define geq (a,b,c) avg(a,b,c) >= 60
#define lee (a,b,c) avg(a,b,c) <= 60
#define des (a,b,c,d) (d==1?geq(a,b,c):lee(a,b,c))
void main (void)
{
int num = 70;
char ch = ,0,;
float f = 2.0;
if des(num,ch,f,0) puts ("lee..");
else puts("geq...");
}
a. syntax error b. geq... will be displayed c. lee.. will be displayed
d. none e. Not sure

9. Which of the following statement is correct?
a. sizeof(,*,) is equal to sizeof(int) b. sizeof(,*,) is equal to sizeof(char)
c. sizeof(,*,) is equal to sizeof(double) d. none e. Not sure

10. What does the following program print?
#include
char *rev(int val);
void main(void)
{
extern char dec[];
printf ("%c", *rev);
}
char *rev (int val)
{
char dec[]="abcde";
return dec;
}
a. prints abcde b. prints the address of the array dec
c. prints garbage, address of the local variable should not returned d. print a e. Not sure

11. What does the following program print?
void main(void)
{
int i;
static int k;
if(k==,0,)
printf("one");
else if(k== 48)
printf("two");
else
printf("three");
}
a. prints one b. prints two c. prints three
d. prints one three e. Not sure

12. What does the following program print?
#include
void main(void)
{
enum sub
{
chemistry, maths, physics
};
struct result
{
char name[30];
enum sub sc;
};
struct result my_res;
strcpy (my_res.name,"Patrick");
my_res.sc=physics;
printf("name: %s\n",my_res.name);
printf("pass in subject: %d\n",my_res.sc);
}
a. name: Patrick b. name: Patrick c. name: Patrick
pass in subject: 2 pass in subject:3 pass in subject:0
d. gives compilation errors e. Not sure

13. What does
printf("%s",_FILE_); and printf("%d",_LINE_); do?
a. the first printf prints the name of the file and the second printf prints the line no: of the second printf in the file
b. _FILE_ and _LINE_ are not valid parameters to printf function
c. linker errors will be generated d. compiler errors will be generated e. Not sure

14. What is the output of the following program?
#include
void swap (int x, int y, int t)
{
t = x;
x = y;
y = t;
printf ("x inside swap: %d\t y inside swap : %d\n",x,y);
}
void main(void)
{
int x;
int y;
int t;
x = 99;
y = 100;
swap (x,y,t);
printf ("x inside main:%d\t y inside main: %d",x,y);
}
a. x inside swap : 100 y inside swap : 99 x inside main : 100 y inside main : 99
b. x inside swap : 100 y inside swap : 99 x inside main : 99 y inside main : 100
c. x inside swap : 99 y inside swap : 100 x inside main : 99 y inside main : 100
d. x inside swap : 99 y inside swap : 100 x inside main : 100 y inside main : 99
e. Not sure

15. Consider the following statements:
i) " while loop " is top tested loop ii) " for loop " is bottom tested loop
iii) " do - while loop" is top tested loop iv) " while loop" and "do - while loop " are top tested loops.
Which among the above statements are false?
a. i only b. i & ii c. iii & i d. ii, iii & iv e. Not sure

16. Consider the following piece of code:
char *p = "MISTRAL";
printf ("%c\t", *(++p));
p -=1;
printf ("%c\t", *(p++));
Now, what does the two printf,s display?
a. M M b. M I c. I M d. M S e. Not sure


17. What does the following program print?
#include
struct my_struct
{
int p:1;
int q:1;
int r:6;
int s:2;
};
struct my_struct bigstruct;
struct my_struct1
{
char m:1;
};
struct my_struct1 small struct;
void main (void)
{
printf ("%d %d\n",sizeof (bigstruct),sizeof (smallstruct));
}
a. 10 1 b. 2 2 c. 2 1 d. 1 1 e. Not sure

18. Consider the following piece of code:
FILE *fp;
fp = fopen("myfile.dat","r");
Now fp points to
a. the first character in the file.
b. a structure which contains a char pointer which points to the first character in the file.
c. the name of the file. d. none of the above. e. Not sure.

19. What does the following program print?
#include
#define SQR (x) (x*x)
void main(void)
{
int a,b=3;
a = SQR (b+2);
}
a. 25 b. 11 c. 17 d. 21 e. Not sure.

20. What does the declaration do?
int (*mist) (void *, void *);
a. declares mist as a function that takes two void * arguments and returns a pointer to an int.
b. declares mist as a pointer to a function that has two void * arguments and returns an int.
c. declares mist as a function that takes two void * arguments and returns an int.
d. there is a syntax error in the declaration. e. Not sure.


21. What does the following program print?
#include
void main (void)
{
int mat [5][5],i,j;
int *p;
p = & mat [0][0];
for (i=0;i<5;i++)
for (j=0;j<5;j++)
mat[i][j] = i+j;
printf ("%d\t", sizeof(mat)); < BR> i=4;j=5;
printf( "%d", *(p+i+j));
}
a. 25 9 b. 25 5 c. 50 9 d. 50 5 e. Not sure

22. What is the output of the following program?
#include
void main (void)
{
short x = 0x3333;
short y = 0x4321;
long z = x;
z = z << 16;
z = z | y;
printf("%1x\t",z);
z = y;
z = z >> 16;
z = z | x;
printf("%1x\t",z);
z = x;
y = x && y;
z = y;
printf("%1x\t",z);
}
a. 43213333 3333 1 b. 33334321 4321 4321 c. 33334321 3333 1
d. 43213333 4321 4321 e. Not sure

23. What is the output of the following program?
#include
void main (void)
{
char *p = "Bangalore";
#if 0
printf ("%s", p);
#endif
}
a. syntax error #if cannot be used inside main function b. prints Bangalore on the screen
c. does not print anything on the screen
d. program gives an error "undefined symbol if" e. Not sure

24. If x is declared as an integer, y is declared as float, consider the following expression:
y = *(float *)&x;
Which one of the following statments is true?
a. the program containing the expression produces compilation errors;
b. the program containing the expression produces runtime errors;
c. the program containing the expression compiles and runs without any errors;
d. none of the above e. Not sure

25. What is the return type of calloc function?
a. int * b. void * c. no return type: return type is void
d. int e. Not sure


Mistral Placement Paper : Aptitude - General

Mistral Solutions

C Section

1. What does the following program print?
#include
int sum,count;
void main(void)
{< BR> for(count=5;sum+=--count;)
printf("%d",sum);
}
a. The pgm goes to an infinite loop b. Prints 4791010974 c. Prints 4791001974
d. Prints 5802112085 e. Not sure

2. What is the output of the following program?
#include
void main(void)
{
int i;< BR> for(i=2;i<=7;i++)
printf("%5d",fno());
}
fno()
{
staticintf1=1,f2=1,f3;
return(f3=f1+f2,f1=f2,f2=f3);
}
a. produce syntax errors b. 2 3 5 8 13 21 will be displayed c. 2 2 2 2 2 2 will be displayed
d. none of the above e. Not sure

3. What is the output of the following program?
#include
void main (void)
{
int x = 0x1234;
int y = 0x5678;
x = x & 0x5678;
y = y | 0x1234;
x = x^y;
printf("%x\t",x);
x = x | 0x5678;
y = y & 0x1234;
y = y^x;
printf("%x\t",y);
}
a. bbb3 bbb7 b. bbb7 bbb3 c. 444c 4448
d. 4448 444c e. Not sure

4. What does the following program print?
#include
void main (void)
{
int x;
x = 0;
if (x=0)
printf ("Value of x is 0");
else
printf ("Value of x is not 0");
}
a. print value of x is 0 b. print value of x is not 0 c. does not print anything on the screen
d. there is a syntax error in the if statement e. Not sure

5. What is the output of the following program?
#include
#include
int foo(char *);
void main (void)
{
char arr[100] = {"Welcome to Mistral"};
foo (arr);
}
foo (char *x)
{
printf ("%d\t",strlen (x));
printf ("%d\t",sizeof(x));
return0;
}
a. 100 100 b. 18 100 c. 18 18 d. 18 2 e. Not sure

6. What is the output of the following program?
#include
display()
{
printf ("\n Hello World");
return 0;
}
void main (void)
{
int (* func_ptr) ();
func_ptr = display;
printf ("\n %u",func_ptr);
(* func_ptr) ();
}
a. it prints the address of the function display and prints Hello World on the screen
b. it prints Hello World two times on the screen
c. it prints only the address of the fuction display on the screen
d. there is an error in the program e. Not sure

7. What is the output of the following program?
#include
void main (void)
{
int i = 0;
char ch = ,A,;
do
putchar (ch);
while(i++ < 5 || ++ch <= ,F,);
}
a. ABCDEF will be displayed b. AAAAAABCDEF will displayed
c. character ,A, will be displayed infinitely d. none e. Not sure

8. What is the output of the following program?
#include
#define sum (a,b,c) a+b+c
#define avg (a,b,c) sum(a,b,c)/3
#define geq (a,b,c) avg(a,b,c) >= 60
#define lee (a,b,c) avg(a,b,c) <= 60
#define des (a,b,c,d) (d==1?geq(a,b,c):lee(a,b,c))
void main (void)
{
int num = 70;
char ch = ,0,;
float f = 2.0;
if des(num,ch,f,0) puts ("lee..");
else puts("geq...");
}
a. syntax error b. geq... will be displayed c. lee.. will be displayed
d. none e. Not sure

9. Which of the following statement is correct?
a. sizeof(,*,) is equal to sizeof(int) b. sizeof(,*,) is equal to sizeof(char)
c. sizeof(,*,) is equal to sizeof(double) d. none e. Not sure

10. What does the following program print?
#include
char *rev(int val);
void main(void)
{
extern char dec[];
printf ("%c", *rev);
}
char *rev (int val)
{
char dec[]="abcde";
return dec;
}
a. prints abcde b. prints the address of the array dec
c. prints garbage, address of the local variable should not returned d. print a e. Not sure

11. What does the following program print?
void main(void)
{
int i;
static int k;
if(k==,0,)
printf("one");
else if(k== 48)
printf("two");
else
printf("three");
}
a. prints one b. prints two c. prints three
d. prints one three e. Not sure

12. What does the following program print?
#include
void main(void)
{
enum sub
{
chemistry, maths, physics
};
struct result
{
char name[30];
enum sub sc;
};
struct result my_res;
strcpy (my_res.name,"Patrick");
my_res.sc=physics;
printf("name: %s\n",my_res.name);
printf("pass in subject: %d\n",my_res.sc);
}
a. name: Patrick b. name: Patrick c. name: Patrick
pass in subject: 2 pass in subject:3 pass in subject:0
d. gives compilation errors e. Not sure

13. What does
printf("%s",_FILE_); and printf("%d",_LINE_); do?
a. the first printf prints the name of the file and the second printf prints the line no: of the second printf in the file
b. _FILE_ and _LINE_ are not valid parameters to printf function
c. linker errors will be generated d. compiler errors will be generated e. Not sure

14. What is the output of the following program?
#include
void swap (int x, int y, int t)
{
t = x;
x = y;
y = t;
printf ("x inside swap: %d\t y inside swap : %d\n",x,y);
}
void main(void)
{
int x;
int y;
int t;
x = 99;
y = 100;
swap (x,y,t);
printf ("x inside main:%d\t y inside main: %d",x,y);
}
a. x inside swap : 100 y inside swap : 99 x inside main : 100 y inside main : 99
b. x inside swap : 100 y inside swap : 99 x inside main : 99 y inside main : 100
c. x inside swap : 99 y inside swap : 100 x inside main : 99 y inside main : 100
d. x inside swap : 99 y inside swap : 100 x inside main : 100 y inside main : 99
e. Not sure

15. Consider the following statements:
i) " while loop " is top tested loop ii) " for loop " is bottom tested loop
iii) " do - while loop" is top tested loop iv) " while loop" and "do - while loop " are top tested loops.
Which among the above statements are false?
a. i only b. i & ii c. iii & i d. ii, iii & iv e. Not sure

16. Consider the following piece of code:
char *p = "MISTRAL";
printf ("%c\t", *(++p));
p -=1;
printf ("%c\t", *(p++));
Now, what does the two printf,s display?
a. M M b. M I c. I M d. M S e. Not sure


17. What does the following program print?
#include
struct my_struct
{
int p:1;
int q:1;
int r:6;
int s:2;
};
struct my_struct bigstruct;
struct my_struct1
{
char m:1;
};
struct my_struct1 small struct;
void main (void)
{
printf ("%d %d\n",sizeof (bigstruct),sizeof (smallstruct));
}
a. 10 1 b. 2 2 c. 2 1 d. 1 1 e. Not sure

18. Consider the following piece of code:
FILE *fp;
fp = fopen("myfile.dat","r");
Now fp points to
a. the first character in the file.
b. a structure which contains a char pointer which points to the first character in the file.
c. the name of the file. d. none of the above. e. Not sure.

19. What does the following program print?
#include
#define SQR (x) (x*x)
void main(void)
{
int a,b=3;
a = SQR (b+2);
}
a. 25 b. 11 c. 17 d. 21 e. Not sure.

20. What does the declaration do?
int (*mist) (void *, void *);
a. declares mist as a function that takes two void * arguments and returns a pointer to an int.
b. declares mist as a pointer to a function that has two void * arguments and returns an int.
c. declares mist as a function that takes two void * arguments and returns an int.
d. there is a syntax error in the declaration. e. Not sure.


21. What does the following program print?
#include
void main (void)
{
int mat [5][5],i,j;
int *p;
p = & mat [0][0];
for (i=0;i<5;i++)
for (j=0;j<5;j++)
mat[i][j] = i+j;
printf ("%d\t", sizeof(mat)); < BR> i=4;j=5;
printf( "%d", *(p+i+j));
}
a. 25 9 b. 25 5 c. 50 9 d. 50 5 e. Not sure

22. What is the output of the following program?
#include
void main (void)
{
short x = 0x3333;
short y = 0x4321;
long z = x;
z = z << 16;
z = z | y;
printf("%1x\t",z);
z = y;
z = z >> 16;
z = z | x;
printf("%1x\t",z);
z = x;
y = x && y;
z = y;
printf("%1x\t",z);
}
a. 43213333 3333 1 b. 33334321 4321 4321 c. 33334321 3333 1
d. 43213333 4321 4321 e. Not sure

23. What is the output of the following program?
#include
void main (void)
{
char *p = "Bangalore";
#if 0
printf ("%s", p);
#endif
}
a. syntax error #if cannot be used inside main function b. prints Bangalore on the screen
c. does not print anything on the screen
d. program gives an error "undefined symbol if" e. Not sure

24. If x is declared as an integer, y is declared as float, consider the following expression:
y = *(float *)&x;
Which one of the following statments is true?
a. the program containing the expression produces compilation errors;
b. the program containing the expression produces runtime errors;
c. the program containing the expression compiles and runs without any errors;
d. none of the above e. Not sure

25. What is the return type of calloc function?
a. int * b. void * c. no return type: return type is void
d. int e. Not sure


Mistral Placement Paper : Mistral Paper Technical - C & C++

 Mistral Solutions

C Section

1. What does the following program print?
#include <stio.h>
int sum,count;
void main(void)
{< BR> for(count=5;sum+=--count;)
printf("%d",sum);
}
a. The pgm goes to an infinite loop b. Prints 4791010974 c. Prints 4791001974
d. Prints 5802112085 e. Not sure

2. What is the output of the following program?
#include <stdio.h>
void main(void)
{
int i;< BR> for(i=2;i<=7;i++)
printf("%5d",fno());
}
fno()
{
staticintf1=1,f2=1,f3;
return(f3=f1+f2,f1=f2,f2=f3);
}
a. produce syntax errors b. 2 3 5 8 13 21 will be displayed c. 2 2 2 2 2 2 will be displayed
d. none of the above e. Not sure

3. What is the output of the following program?
#include <stdio.h>
void main (void)
{
int x = 0x1234;
int y = 0x5678;
x = x & 0x5678;
y = y | 0x1234;
x = x^y;
printf("%x\t",x);
x = x | 0x5678;
y = y & 0x1234;
y = y^x;
printf("%x\t",y);
}
a. bbb3 bbb7 b. bbb7 bbb3 c. 444c 4448
d. 4448 444c e. Not sure

4. What does the following program print?
#include <stdio.h>
void main (void)
{
int x;
x = 0;
if (x=0)
printf ("Value of x is 0");
else
printf ("Value of x is not 0");
}
a. print value of x is 0 b. print value of x is not 0 c. does not print anything on the screen
d. there is a syntax error in the if statement e. Not sure

5. What is the output of the following program?
#include <stdio.h>
#include <string.h>
int foo(char *);
void main (void)
{
char arr[100] = {"Welcome to Mistral"};
foo (arr);
}
foo (char *x)
{
printf ("%d\t",strlen (x));
printf ("%d\t",sizeof(x));
return0;
}
a. 100 100 b. 18 100 c. 18 18 d. 18 2 e. Not sure

6. What is the output of the following program?
#include <stdio.h>
display()
{
printf ("\n Hello World");
return 0;
}
void main (void)
{
int (* func_ptr) ();
func_ptr = display;
printf ("\n %u",func_ptr);
(* func_ptr) ();
}
a. it prints the address of the function display and prints Hello World on the screen
b. it prints Hello World two times on the screen
c. it prints only the address of the fuction display on the screen
d. there is an error in the program e. Not sure

7. What is the output of the following program?
#include <stdio.h>
void main (void)
{
int i = 0;
char ch = ,A,;
do
putchar (ch);
while(i++ < 5 || ++ch <= ,F,);
}
a. ABCDEF will be displayed b. AAAAAABCDEF will displayed
c. character ,A, will be displayed infinitely d. none e. Not sure

8. What is the output of the following program?
#include <stdio.h>
#define sum (a,b,c) a+b+c
#define avg (a,b,c) sum(a,b,c)/3
#define geq (a,b,c) avg(a,b,c) >= 60
#define lee (a,b,c) avg(a,b,c) <= 60
#define des (a,b,c,d) (d==1?geq(a,b,c):lee(a,b,c))
void main (void)
{
int num = 70;
char ch = ,0,;
float f = 2.0;
if des(num,ch,f,0) puts ("lee..");
else puts("geq...");
}
a. syntax error b. geq... will be displayed c. lee.. will be displayed
d. none e. Not sure

9. Which of the following statement is correct?
a. sizeof(,*,) is equal to sizeof(int) b. sizeof(,*,) is equal to sizeof(char)
c. sizeof(,*,) is equal to sizeof(double) d. none e. Not sure

10. What does the following program print?
#include <stdio.h>
char *rev(int val);
void main(void)
{
extern char dec[];
printf ("%c", *rev);
}
char *rev (int val)
{
char dec[]="abcde";
return dec;
}
a. prints abcde b. prints the address of the array dec
c. prints garbage, address of the local variable should not returned d. print a e. Not sure

11. What does the following program print?
void main(void)
{
int i;
static int k;
if(k==,0,)
printf("one");
else if(k== 48)
printf("two");
else
printf("three");
}
a. prints one b. prints two c. prints three
d. prints one three e. Not sure

12. What does the following program print?
#include<stdio.h>
void main(void)
{
enum sub
{
chemistry, maths, physics
};
struct result
{
char name[30];
enum sub sc;
};
struct result my_res;
strcpy (my_res.name,"Patrick");
my_res.sc=physics;
printf("name: %s\n",my_res.name);
printf("pass in subject: %d\n",my_res.sc);
}
a. name: Patrick b. name: Patrick c. name: Patrick
pass in subject: 2 pass in subject:3 pass in subject:0
d. gives compilation errors e. Not sure

13. What does
printf("%s",_FILE_); and printf("%d",_LINE_); do?
a. the first printf prints the name of the file and the second printf prints the line no: of the second printf in the file
b. _FILE_ and _LINE_ are not valid parameters to printf function
c. linker errors will be generated d. compiler errors will be generated e. Not sure

14. What is the output of the following program?
#include <stdio.h>
void swap (int x, int y, int t)
{
t = x;
x = y;
y = t;
printf ("x inside swap: %d\t y inside swap : %d\n",x,y);
}
void main(void)
{
int x;
int y;
int t;
x = 99;
y = 100;
swap (x,y,t);
printf ("x inside main:%d\t y inside main: %d",x,y);
}
a. x inside swap : 100 y inside swap : 99 x inside main : 100 y inside main : 99
b. x inside swap : 100 y inside swap : 99 x inside main : 99 y inside main : 100
c. x inside swap : 99 y inside swap : 100 x inside main : 99 y inside main : 100
d. x inside swap : 99 y inside swap : 100 x inside main : 100 y inside main : 99
e. Not sure

15. Consider the following statements:
i) " while loop " is top tested loop ii) " for loop " is bottom tested loop
iii) " do - while loop" is top tested loop iv) " while loop" and "do - while loop " are top tested loops.
Which among the above statements are false?
a. i only b. i & ii c. iii & i d. ii, iii & iv e. Not sure

16. Consider the following piece of code:
char *p = "MISTRAL";
printf ("%c\t", *(++p));
p -=1;
printf ("%c\t", *(p++));
Now, what does the two printf,s display?
a. M M b. M I c. I M d. M S e. Not sure


17. What does the following program print?
#include <stdio.h>
struct my_struct
{
int p:1;
int q:1;
int r:6;
int s:2;
};
struct my_struct bigstruct;
struct my_struct1
{
char m:1;
};
struct my_struct1 small struct;
void main (void)
{
printf ("%d %d\n",sizeof (bigstruct),sizeof (smallstruct));
}
a. 10 1 b. 2 2 c. 2 1 d. 1 1 e. Not sure

18. Consider the following piece of code:
FILE *fp;
fp = fopen("myfile.dat","r");
Now fp points to
a. the first character in the file.
b. a structure which contains a char pointer which points to the first character in the file.
c. the name of the file. d. none of the above. e. Not sure.

19. What does the following program print?
#include <stdio.h>
#define SQR (x) (x*x)
void main(void)
{
int a,b=3;
a = SQR (b+2);
}
a. 25 b. 11 c. 17 d. 21 e. Not sure.

20. What does the declaration do?
int (*mist) (void *, void *);
a. declares mist as a function that takes two void * arguments and returns a pointer to an int.
b. declares mist as a pointer to a function that has two void * arguments and returns an int.
c. declares mist as a function that takes two void * arguments and returns an int.
d. there is a syntax error in the declaration. e. Not sure.


21. What does the following program print?
#include <stdio.h>
void main (void)
{
int mat [5][5],i,j;
int *p;
p = & mat [0][0];
for (i=0;i<5;i++)
for (j=0;j<5;j++)
mat[i][j] = i+j;
printf ("%d\t", sizeof(mat)); < BR> i=4;j=5;
printf( "%d", *(p+i+j));
}
a. 25 9 b. 25 5 c. 50 9 d. 50 5 e. Not sure

22. What is the output of the following program?
#include <stdio.h>
void main (void)
{
short x = 0x3333;
short y = 0x4321;
long z = x;
z = z << 16;
z = z | y;
printf("%1x\t",z);
z = y;
z = z >> 16;
z = z | x;
printf("%1x\t",z);
z = x;
y = x && y;
z = y;
printf("%1x\t",z);
}
a. 43213333 3333 1 b. 33334321 4321 4321 c. 33334321 3333 1
d. 43213333 4321 4321 e. Not sure

23. What is the output of the following program?
#include <stdio.h>
void main (void)
{
char *p = "Bangalore";
#if 0
printf ("%s", p);
#endif
}
a. syntax error #if cannot be used inside main function b. prints Bangalore on the screen
c. does not print anything on the screen
d. program gives an error "undefined symbol if" e. Not sure

24. If x is declared as an integer, y is declared as float, consider the following expression:
y = *(float *)&x;
Which one of the following statments is true?
a. the program containing the expression produces compilation errors;
b. the program containing the expression produces runtime errors;
c. the program containing the expression compiles and runs without any errors;
d. none of the above e. Not sure

25. What is the return type of calloc function?
a. int * b. void * c. no return type: return type is void
d. int e. Not sure

Mistral Placement Paper : Mistral Paper Aptitude - General

Mistral Solutions

C Section

1. What does the following program print?
#include <stio.h>
int sum,count;
void main(void)
{< BR> for(count=5;sum+=--count;)
printf("%d",sum);
}
a. The pgm goes to an infinite loop b. Prints 4791010974 c. Prints 4791001974
d. Prints 5802112085 e. Not sure

2. What is the output of the following program?
#include <stdio.h>
void main(void)
{
int i;< BR> for(i=2;i<=7;i++)
printf("%5d",fno());
}
fno()
{
staticintf1=1,f2=1,f3;
return(f3=f1+f2,f1=f2,f2=f3);
}
a. produce syntax errors b. 2 3 5 8 13 21 will be displayed c. 2 2 2 2 2 2 will be displayed
d. none of the above e. Not sure

3. What is the output of the following program?
#include <stdio.h>
void main (void)
{
int x = 0x1234;
int y = 0x5678;
x = x & 0x5678;
y = y | 0x1234;
x = x^y;
printf("%x\t",x);
x = x | 0x5678;
y = y & 0x1234;
y = y^x;
printf("%x\t",y);
}
a. bbb3 bbb7 b. bbb7 bbb3 c. 444c 4448
d. 4448 444c e. Not sure

4. What does the following program print?
#include <stdio.h>
void main (void)
{
int x;
x = 0;
if (x=0)
printf ("Value of x is 0");
else
printf ("Value of x is not 0");
}
a. print value of x is 0 b. print value of x is not 0 c. does not print anything on the screen
d. there is a syntax error in the if statement e. Not sure

5. What is the output of the following program?
#include <stdio.h>
#include <string.h>
int foo(char *);
void main (void)
{
char arr[100] = {"Welcome to Mistral"};
foo (arr);
}
foo (char *x)
{
printf ("%d\t",strlen (x));
printf ("%d\t",sizeof(x));
return0;
}
a. 100 100 b. 18 100 c. 18 18 d. 18 2 e. Not sure

6. What is the output of the following program?
#include <stdio.h>
display()
{
printf ("\n Hello World");
return 0;
}
void main (void)
{
int (* func_ptr) ();
func_ptr = display;
printf ("\n %u",func_ptr);
(* func_ptr) ();
}
a. it prints the address of the function display and prints Hello World on the screen
b. it prints Hello World two times on the screen
c. it prints only the address of the fuction display on the screen
d. there is an error in the program e. Not sure

7. What is the output of the following program?
#include <stdio.h>
void main (void)
{
int i = 0;
char ch = ,A,;
do
putchar (ch);
while(i++ < 5 || ++ch <= ,F,);
}
a. ABCDEF will be displayed b. AAAAAABCDEF will displayed
c. character ,A, will be displayed infinitely d. none e. Not sure

8. What is the output of the following program?
#include <stdio.h>
#define sum (a,b,c) a+b+c
#define avg (a,b,c) sum(a,b,c)/3
#define geq (a,b,c) avg(a,b,c) >= 60
#define lee (a,b,c) avg(a,b,c) <= 60
#define des (a,b,c,d) (d==1?geq(a,b,c):lee(a,b,c))
void main (void)
{
int num = 70;
char ch = ,0,;
float f = 2.0;
if des(num,ch,f,0) puts ("lee..");
else puts("geq...");
}
a. syntax error b. geq... will be displayed c. lee.. will be displayed
d. none e. Not sure

9. Which of the following statement is correct?
a. sizeof(,*,) is equal to sizeof(int) b. sizeof(,*,) is equal to sizeof(char)
c. sizeof(,*,) is equal to sizeof(double) d. none e. Not sure

10. What does the following program print?
#include <stdio.h>
char *rev(int val);
void main(void)
{
extern char dec[];
printf ("%c", *rev);
}
char *rev (int val)
{
char dec[]="abcde";
return dec;
}
a. prints abcde b. prints the address of the array dec
c. prints garbage, address of the local variable should not returned d. print a e. Not sure

11. What does the following program print?
void main(void)
{
int i;
static int k;
if(k==,0,)
printf("one");
else if(k== 48)
printf("two");
else
printf("three");
}
a. prints one b. prints two c. prints three
d. prints one three e. Not sure

12. What does the following program print?
#include<stdio.h>
void main(void)
{
enum sub
{
chemistry, maths, physics
};
struct result
{
char name[30];
enum sub sc;
};
struct result my_res;
strcpy (my_res.name,"Patrick");
my_res.sc=physics;
printf("name: %s\n",my_res.name);
printf("pass in subject: %d\n",my_res.sc);
}
a. name: Patrick b. name: Patrick c. name: Patrick
pass in subject: 2 pass in subject:3 pass in subject:0
d. gives compilation errors e. Not sure

13. What does
printf("%s",_FILE_); and printf("%d",_LINE_); do?
a. the first printf prints the name of the file and the second printf prints the line no: of the second printf in the file
b. _FILE_ and _LINE_ are not valid parameters to printf function
c. linker errors will be generated d. compiler errors will be generated e. Not sure

14. What is the output of the following program?
#include <stdio.h>
void swap (int x, int y, int t)
{
t = x;
x = y;
y = t;
printf ("x inside swap: %d\t y inside swap : %d\n",x,y);
}
void main(void)
{
int x;
int y;
int t;
x = 99;
y = 100;
swap (x,y,t);
printf ("x inside main:%d\t y inside main: %d",x,y);
}
a. x inside swap : 100 y inside swap : 99 x inside main : 100 y inside main : 99
b. x inside swap : 100 y inside swap : 99 x inside main : 99 y inside main : 100
c. x inside swap : 99 y inside swap : 100 x inside main : 99 y inside main : 100
d. x inside swap : 99 y inside swap : 100 x inside main : 100 y inside main : 99
e. Not sure

15. Consider the following statements:
i) " while loop " is top tested loop ii) " for loop " is bottom tested loop
iii) " do - while loop" is top tested loop iv) " while loop" and "do - while loop " are top tested loops.
Which among the above statements are false?
a. i only b. i & ii c. iii & i d. ii, iii & iv e. Not sure

16. Consider the following piece of code:
char *p = "MISTRAL";
printf ("%c\t", *(++p));
p -=1;
printf ("%c\t", *(p++));
Now, what does the two printf,s display?
a. M M b. M I c. I M d. M S e. Not sure


17. What does the following program print?
#include <stdio.h>
struct my_struct
{
int p:1;
int q:1;
int r:6;
int s:2;
};
struct my_struct bigstruct;
struct my_struct1
{
char m:1;
};
struct my_struct1 small struct;
void main (void)
{
printf ("%d %d\n",sizeof (bigstruct),sizeof (smallstruct));
}
a. 10 1 b. 2 2 c. 2 1 d. 1 1 e. Not sure

18. Consider the following piece of code:
FILE *fp;
fp = fopen("myfile.dat","r");
Now fp points to
a. the first character in the file.
b. a structure which contains a char pointer which points to the first character in the file.
c. the name of the file. d. none of the above. e. Not sure.

19. What does the following program print?
#include <stdio.h>
#define SQR (x) (x*x)
void main(void)
{
int a,b=3;
a = SQR (b+2);
}
a. 25 b. 11 c. 17 d. 21 e. Not sure.

20. What does the declaration do?
int (*mist) (void *, void *);
a. declares mist as a function that takes two void * arguments and returns a pointer to an int.
b. declares mist as a pointer to a function that has two void * arguments and returns an int.
c. declares mist as a function that takes two void * arguments and returns an int.
d. there is a syntax error in the declaration. e. Not sure.


21. What does the following program print?
#include <stdio.h>
void main (void)
{
int mat [5][5],i,j;
int *p;
p = & mat [0][0];
for (i=0;i<5;i++)
for (j=0;j<5;j++)
mat[i][j] = i+j;
printf ("%d\t", sizeof(mat)); < BR> i=4;j=5;
printf( "%d", *(p+i+j));
}
a. 25 9 b. 25 5 c. 50 9 d. 50 5 e. Not sure

22. What is the output of the following program?
#include <stdio.h>
void main (void)
{
short x = 0x3333;
short y = 0x4321;
long z = x;
z = z << 16;
z = z | y;
printf("%1x\t",z);
z = y;
z = z >> 16;
z = z | x;
printf("%1x\t",z);
z = x;
y = x && y;
z = y;
printf("%1x\t",z);
}
a. 43213333 3333 1 b. 33334321 4321 4321 c. 33334321 3333 1
d. 43213333 4321 4321 e. Not sure

23. What is the output of the following program?
#include <stdio.h>
void main (void)
{
char *p = "Bangalore";
#if 0
printf ("%s", p);
#endif
}
a. syntax error #if cannot be used inside main function b. prints Bangalore on the screen
c. does not print anything on the screen
d. program gives an error "undefined symbol if" e. Not sure

24. If x is declared as an integer, y is declared as float, consider the following expression:
y = *(float *)&x;
Which one of the following statments is true?
a. the program containing the expression produces compilation errors;
b. the program containing the expression produces runtime errors;
c. the program containing the expression compiles and runs without any errors;
d. none of the above e. Not sure

25. What is the return type of calloc function?
a. int * b. void * c. no return type: return type is void
d. int e. Not sure


 

By Category
Post Your Resume Here