You are on page 1of 5

C questions

1. Whai is a pointer?
2. What is a structure?
3 Whfjl ;ti e the differences between structures and arrays?
4. In header fi'.es whether functions are declared or defined?
5. Whal are the differences between malloc and cailoc!"?
#. Whal sre macros? what are its ad$anta%es and disad$anta%es?
&. 'ifference between pass by reference and pass by $alue?
(. Whot is static identifier?
). Wru*?re are the auto $ariables stored?
tfl. Where does %lobal+ static+ local+ re%ister $ariables+ tree memory and ! ,ro%ram
instructions %et stored?
11. 'ifference between arrays and lin-ed list?
12. What are enumerations?
13. 'escribe about stora%e allocation and scope of %lobal+ e.tern+ static+ local and re%ister
$ariables?
1/. What are re%ister $ariables? What are the ad$anta%e of usin% re%ister $ariables?
15. What is the use of typedef?
1#. !an we specify $ariable field width in a scanf0 format strin%? If possible how?
1&. ut of f%ets0 and %ets0 which function is safe to use and why?
1(. 'ifference between strdup and strcpy?
1). What is recursion?
21. 'ifferentiate between a f or loop and a while loop? What are it uses?
21. What are the different stora%e classes in !?
22. Write down the e2ui$alent pointer e.pression for referrin% the same element a3i4053-43l4?
23. What is difference between 6tructure and 7nions?
2/. What the ad$anta%es of usin% 7nions?
25. What aru the ad$anta%es of usin% pointers in a pro%ram? 2#*
What is the difference between 6trin%s and 8rrays?
2&. In a header file whether functions are declared or defined?
2(. Whyt is a far pointer? where we use it?
2). 9ow will you declare an array of three function pointers where each function recei$e? twp ints
and returns a float?
31. what is a :7;; ,ointer? Whether it is same as an uninitiali<ed pointer?
31. What is a :7;; =acro? What is the difference between a :7;; ,ointer and a :7;; =acro?
32. What does the error ':ull ,ointer 8ssi%nment' mean and what causes this error?
33. What is near+ far and hu%e pointers? 9ow many bytes are occupied by them?
3/. 9ow would you obtain se%ment and offset addresses from a far address of a memory
location? 55. 8re the e.pressions arr and >arr same for an array of
inte%ers?
3#. 'oes mentionin% the array name %i$es the base address in all the conte.ts?
3&. ?.plaih one method to process an entire strin% as one unit?
3(. What is the similarity between a 6tructure+ 7nion and enumeration?
3). !an a 6tructure contain a ,ointer to itself?
/1. 9ow can we chec- whether the contents of two structure $ariables are same or not?
/1. 9ow are 6tructure passin% and returnin% implemented by the compiler?
/2. 9ow can we read@write 6tructures from@ts data files?
/3. What it; the difference between an enumeration arid a set of pre*processorA defines?
//. what do the 'c' and B in ar%c and ar%$ stand for?
/5. 8re the $ariables ar%c and sr%$ are local to main?
/#. What is the ma.imum combined len%th of command line ar%uments includin% the space
between adjacent ar%uments?
/&. If we want that any wildcard characters in the command line ar%uments should be
appropriately e.panded+ are we re2uired to ma-e any special pro$ision? If y+es+ which?
/(. 'oes there e.ist any way to ma-e the command line ar%uments a$ailable to other
functions without passin% them as ar%uments to the function?
/). What are bit fields? What is the use of bit fields in a 6tructure declaration?
51. Co which numberin% system can the binary number 1111111111111111 be easily con$erted
to?
51. Which bit wise operator is suitable for chec-in% whether a particular bit is on or off?
52. Which bit wise operator is suitable for turnin% off a particular bit in a number?
53. Which bit wise operator is suitable for puttin% on a particular bit in a number?
5/. Which bit wise operator is suitable for chec-in% whether a particular bit is on or off?
55. which one is e2ui$alent to multiplyin% by 2D;eft shiftin% a number by 1 or ;eft shiftin% an
unsi%ned int or char by 1?
5#. Write a pro%ram to compare two strin%s without usin% the strcmp0 function.
5&. Write a pro%ram to concatenate two strin%s.
5(. Write a pro%ram to interchan%e 2 $ariables without usin% the third one.
5). Write pro%rams for 6trin% Ee$ersal & ,alindrome chec-
#1. Write a pro%ram to find the Factorial of a number
#1. Write a pro%ram to %enerate the Fibinbcci 6eries
#2. Write a pro%ram which employs Eecursion
#3. Write a pro%ram which uses'!ommand ;ine 8r%uments
#/. Write a pro%ram which uses functions li-e strcmp0+ strcpy0? etc
#5. What ere the ad$anta%es of usin% typedef in a pro%ram?
##. 9ow would you dynamically allocate a one*dimensional and two*dimensional array of
inte%ers?
#&. 9ow can you increase the si<e of a dynamically allocated array?
#(. 9ow can you increase the si<e of a statically allocated array?
#). When reallocatin% memory if any other pointers point into the same piece of memory do you
ha$e to readjust these other pointers or do they %et readjusted automatically?
&1. Which function should be used to free the memory allocated by calioc0?
&1. 9ow much ma.imum can you allocate in a sin%le call to malloc0?
&2. +!an you dynamically allocate arrays in e.panded memory?
&3. What is object file? 9ow can you access object file?
&/. Which Waiter file should you include if you are to de$elop a function which can accept $aria>fe
number of ar%uments?
&5. !an you write a function similar to printf? .
&#. 9ow can a called function determine the number of ar%uments that ha$e4 been passed to it?
&&. !an there be at least some solution to determine the number of ar%uments passed to a $ariable
ar%ument list function?
&(. 9ow do you declare the followin%D
o 8n array of three pointers to chars
o 8n array of three char pointers
o 8 pointer to array of three chars
o 8 pointer to function which recei$es an int pointer and returns a float pointer
o 8 pointer to a function which recei$es nothin% and returns nothin%
&). What do the functions atoi'0+ itoa0 and %c$t0 do?
(1. 'oes there e.ist any other function which can be used to con$ert an inte%er or a float to #
sirin%?
(1. 9ow would you use 2sortfj function to sort an array of structures?
(2. 9ow would you use 2sort0 function to sort the name stored in an array of pointers t strin%?
(3. 9ow would you use bsearch0 function to search a name stored in array of pointers to strin%?
(/. 9ow would you use the functions sin+ pow0+ s2rt0?
(5. 9ow would you use the functions memcpy+ memset0+ memmo$e0?
(#. 9ow would you use the functions fsee-0+ freed0+ fwrite0 and ftell0?
(&. 9ow would you obtain the current time and difference between two times+?
((. 9ow would you use the functions randomi<e0 and randomf"?
(). 9ow would you implement a substr0 function that e.tractsGG sub strin% from a %i$en
strin%?
)1. What is the difference between the functions rand0+ randomH"+ srand0 and randotwe0?
)1. What is the difference between the functions memmo$e and memcpy?
)2. 9ow do you Hjrtfli a strin% on the printer?
)3. !an you use the function fprinlf to display the output on the screen? )/ 5
questions
1. What is a class?
2. What is an object?
3. What is the difference between an object and a class?
/. What is the difference between class and structure?
5. What is public+ protected+ pri$ate?
#. What are $irtual functions?
&. What is friend function?
(. What is a scope resolution operator? +).
What do you mean by inheritance?
11. Whai is abstraction?
11. What is polymorphism? ?.plain with an e.ample.
12. What is encapsulation?
13. What do you mean by bindin% of data and functions?
1/. What is function o$erloadin% and operator o$erloadin%?
15. What is $irtual class and friend class?
1#. What do you mean by inline function?
1&. What do you mean by public+ pri$ate+ protected and friendly?
1(. When is an object created and what is its lifetime?
1). What do you mean by multiple inheritance and multile$el inheritance? 'ifferentiate
between them.
21. 'ifference between rea7oc0 and free?
21. What is a template?
22. What are the main differences between procedure oriented lan%ua%es and object
riented lan%ua%es?
23. WhatisECCI?
2/. What are %eneric functions and %eneric classes?
25. What is namespace?
2#. What is the difference between pass by reference and pass by $alue?
2&. Why do we use $irtual functions?
2(. What do you mean by pure $irtual functions?
2). What are $irtual classes?
31. 'oes !II support multile$el and multiple inheritance?
31. What are the ad$anta%es of inheritance?
32. When is a memory allocated to a class?
33. WhJ is the difference between declaration and definition?
3/. Whal is $irtual constructors@destructors?
35. In cIff there is only $irtual destructors+ no constructors. Why?
3#. What' is late bound function call and early bound function call? 'ifferentiate.
3&. 9ow is e.ception handlin% carried out in !II?
3(. When will a constructor e.ecuted? 3(.
What'is 'ynamic ,olymorphism?
/1. Write a macro for swappin% inte%ers.
OPERATING SYSTEM QUESTIONS Go
UP
1. What are the basic functions of an operatin% system?
2. ?.plain briefly about+ processor+ assembler+ compiler+ loader+ lin-er and Hhe functions e.ecuted by
them.
3. What arc the difference phases of software de$elopment? ?.plain briefly?
/. 'ifferentiate between E8= and E=?
5. What is 'E8=? In which form does it store data?
#. What is cache memory?
&. What is hard dis- and what is its purpose?
C+ +
8. Differentiate et!een Co"#i$er an%$fit&r#reter'(' -.
). What are the different tas-s of ;e.ical analysisK+ L
11. What are the different functions of 6ynta. phase+ 6hedulcr?
11. What are the main difference between =icro*!ontroller and =icro* ,rocessorK
12. 'escribe different job schedulin% in operatin% systems.
13. What is a Eeal*Cime 6ystem ?
1/. What is the difference between 9ard and 6oft real*time systems ?
15. What is a mission critical system ?
1#. What is the important aspect of a real*time system ?
1&. If two processes whic'.i shares same system memory and system cloc- in a distributed
system. What is it called?
1(. What is the state of the processor+ when a process is waitin% for some e$ent to occur?
1). What do you mean by deadloc-?
21. ?.plain the difference between micro-ernel and macro -ernel
21. Mi$e an e.ample of micro-ernel.
22. When would you choose bottom up methodolo%y?
23. When would you choose top down methodolo%y?
2/. Write a small dc shell script to find number of FF in the desi%n.
25. Why pa%in% is used ?
2#. Which is the best pa%e replacement al%orithm and Why? 9ow much time ir spent usually in
each phases and why?
2&. 'ifference between ,rimary stora%e and secondary stora%e?
2(. What is mutti tas-in%+ multi pro%rammin%+ multi threadin%?
2). 'ifference between multi threadin% and multi tas-in%?
31. What is software life cycle?
31. 'emand pa%in%+ pa%e faults+ replacement al%orithms+ thrashin%+ etc.
32. ?.plain about pa%ed se%mentation and se%ment pa%in%
33. While runnin% '6 on a ,!+ which command would be used to duplicate the entire
dis-ette?
MICROPROCESSOR QUESTIONS
1. Which type of architecture (1(5 has?
2. 9ow many memory locations can be addressed by a microprocessor with 1/ address
lines?
). 8*8+ is ,o! "an- it "i&ro#ro&essor.
/. Why is data bus bi*directional?
5. What is the function of accumulator?
#. What is fla%+ bus?
&. What are tri*statc de$ices and why they arc essential in a bus oricmcd system?
(. Why are pro%ram counter and stac- pointer 1#*bil re%isters?
). What does it mean by embedded system?
/*. 0,at are t,e %ifferent a%%ressin1 "o%es in 8*8+.
11. What is the difference between =B and =BI?
12. What are the functions of EI=+ 6I=+ I:?
13. What is the immediate addressin% mode?
1/. What are the different fla%s in (1(5&
15. What happens durin% '=8 transfer?
1#. What do you mean by wait state? What is its need?
1&. Whatis,6W?
1(. Whai is 8;?? ?.plain the functions of 8;? in (1(5.
1 ). What is a pro%ram counter? What is its use@
21. What is an interrupt?
2 4. Which line will be acti$ated when an output de$ice re2uire attention from !,7?
E2ECTRONICS QUESTIONS
1. What is meant by '*FF?
2. What is the basic difference between ;atches and Flip flops''
3. What is a multiple.er?
/. 9ow can you con$ert an 6E Flip*flop to a 5N Flip*flop?
5. 9ow can you con$ert an 5N Flip*flop to a ' Flip*flop?
#. What is Eace*around problem? 9ow can you rectify it?
&. Which semiconductor de$ice is used as a $olta%e re%ulator and why?
(. What do.you mean by an ideal $olta%e source?
). What do you mean by <ener brea-down and a$alanche brea-down?
11. What are the different types of filters?
11. What is the need of filterin% ideal response of filters and actual response of filters?
12. What is samplin% theorem?
13. What is impulse response?
1/. ?.plain the ad$anta%es and disad$anta%es of FIE filters compared to IIE counterparts+
15. What is !=EE? ?.plain briefly.
1#. What do you mean by half*duple. and full*duple. communication? ?.plain briefly.
1&. Which ran%e of si%nals are used for terrestrial transmission?
1(. What is the need for modulation?
j )+ Which type of modulation is *used in CB transmission?
2Q. Why we use $esti%ial side band HB6O*!3F" transmission for picture?
"21. When transmittin% di%ital si%nals is it necessary to transmit some harmonics in additionG"
fundamental fre2uency? PP'
22. For asynchronous transmission+ is it necessary to supply some synchroni<in% pulsesK or
11 .supply or to supply start and stop bit?
23. O,F6N is more efficient than OF6N in presence of noise. Why?
2/. What is meant by pre*emphasis and de*emphasis?
25. What do you mean by 3 dO cutoff fre2uency? Wiry is it 3 dO+ not 1 dO?
2#. What do you mean by 86!II+ ?O!'I!?

You might also like