Provided by www.YuvaJobs.com - Global edge Whole Testpaper  GLOBAL EDGE Placement Question Paper 2 2005main(){ int arr[]={ 1,2,3,4 };int *ptr ;;;;ptr++ = arr;printf("%d,%d",ptr[2],arr[2]);return 0;}what is the output :a> compile time error :multiple termination statements for pointerb> lvalue required for ptrc> prints 3 3d> printd 4 3ans b: lvalue required for ptr;2>main(){char s[10];scanf ("%s",s);printf(s);}what is the output if input is abcd :a> prints abcdb> compiler errorc> prints abcd and 6 junk charactersd> printd sans a: prints abcd.3>main(){char c = 255;printf ("%d",c);return 0;}what is the outputa> illegal character assignmentb> prints -1c> prints 2d> prints 255ans b: prints -1.4>main(){int i;for (i=7;i<=0;i--)printf ("hello\n");}what is the outputa> prints hello 7 timesb> prints hello 8 timesc> prints hello onced> prints nothingans b: prints nothing.5>main(){printf( printf ("world") );}a> prints worldb> prints printf ("world")c> prints nothingd> compiler errorans d: compiler error.computer concepts1> A c source code file can bea> compiled onlyb> interpreted onlyc> both compiled and interpretedd> nothingans c : both compiled and interpreted2> c prigramming approach isa> Top downb> bottom upc> both topdown and bottom upd> none of the aboveans a:top down approach3> The access time is less fora> hard diskb> cachec> registersd> main memoryans c:registers4>resolving of external variables in a program is done ata>complie timeb>run timec>link time4>load timeans c: link time.5> interrupts inform process abouta> events external to process asynchronouslyb> events external to process synchronouslyc> both a and bd> events internal to a processans a: events external to process asynchronously/* C question and answersAll questions are tested in Turbo C compalier and have not beentested in gcc or ( linux platform) */----------------------------------------------------1)#include<stdio.h>main(){scanf("%d");printf();}which of the following is correct?a)compilation errorb)Run time errorc)No outputd)depends on the compilerans : a---------------------------------------------------------2)#include<stdio.h>#define islower(c) (,a,<=(c) && (c)<=,z,)#define toupper(c) (islower(c)?(c)-(,a,-,A,)c))main(){char *p="i am fine";while(*p)printf("%c",toupper(*p++));}a)bcdb)AFEc)aFed)BCdans : b ( macro substitution 3 times)----------------------------------------------------------3)#include<stdio.h>main(){200;printf("tricky problem");}a)warning messageb)compilation errorc)run time errord)none of theseans : a------------------------------------------------------------4)which is the null statement?a) ;b) {}c) ,\0,;d)all of theseans : a------------------------------------------------------------5)what is the correct prototype of printf function ?a)printf(char *p,...);b)printf(const *char *p,...);c)printf(const char *p,...);d)printf(const *char p,...);ans : c-----------------------------------------------------------/* questions on computer concepts */1)which of the following is not a system file?a).sysb).comc).inid)noneans : d---------------------------------------------------------------2)A magnetic tape is equivalent to which of the following structure?a)Graphsb)treesc)Listsd)Dictionariesans : c------------------------------------------------------------3)For a linked list implementation which  searching technique is notapplicable?a)linear searchb)nonec)quick sortd)binary searchans : d----------------------------------------------------------------4)Encryption and decryption is done in which layer?a)DLLb)Network layerc)transport layerd) Presentation layerans : d------------------------------------------------------------5)which of the following is not performed by the OS?a)cpu shcedulingb)memory managementc)Transactiond)noneans : c Provided by www.YuvaJobs.com - Global edge Whole Testpaper