tag:blogger.com,1999:blog-80458668205310954762024-03-08T11:58:46.033-08:00COMPUTER GKAMJAD KHANhttp://www.blogger.com/profile/05053334007721250279noreply@blogger.comBlogger6125tag:blogger.com,1999:blog-8045866820531095476.post-2189681101449314062012-02-02T20:08:00.000-08:002012-02-02T20:12:30.878-08:00Variable Name Type Question<div dir="ltr" style="text-align: left;" trbidi="on">1. What will be output of the following c program ? <br />
#include<stdio.h><br />
int abc=10;<br />
int main(){<br />
int abc=20;<br />
printf("%d",abc);<br />
return 0;<br />
}<br />
A) 10<br />
B) 20<br />
C) 30<br />
D) Compilation error<br />
<br />
<b>Answer : B</b><br />
<br />
<b>2. What will be output of the following c program?</b><br />
#include<stdio.h><br />
<br />
int main(){<br />
int main=20;<br />
printf("%d",main);<br />
return 0;<br />
}<br />
A) 80<br />
B) 0<br />
C) 30<br />
D) Compilation error<br />
<br />
<b>Answer :A</b><br />
</div>AMJAD KHANhttp://www.blogger.com/profile/05053334007721250279noreply@blogger.com0tag:blogger.com,1999:blog-8045866820531095476.post-12035293212848670022012-01-31T19:46:00.000-08:002012-02-01T19:25:58.133-08:00Two Line Question of C<div dir="ltr" style="text-align: left;" trbidi="on"><b>1. What are the header file ?</b><br />
<b>2. What is the difference between the functions strdup and atrcpy in C?</b><br />
<b>3. What is difference between for loop and while loop in C language ?</b><br />
<b>4. Write down the equivalent pointer expression for referring the same element as a [i] [j][k][l].</b><br />
<b>5. What does static variable mean?</b><br />
<b>6. What is a pointer ?</b><br />
<b>7. What is a structure ?</b><br />
<b>8. What are the differences between structures and arryas</b><br />
<b>9. In header files whether function are declared or defined </b><br />
<b>10. what are differences between malloc() and calloc()?</b><br />
<b><br />
</b></div>AMJAD KHANhttp://www.blogger.com/profile/05053334007721250279noreply@blogger.com0tag:blogger.com,1999:blog-8045866820531095476.post-68255776363670275742012-01-31T19:31:00.000-08:002012-02-02T19:51:58.582-08:00Objective Question of C Introduction<div dir="ltr" style="text-align: left;" trbidi="on"><b>21. What are the types of linkages </b><br />
A. Internal and External <br />
B. External , Internal and None <br />
C. External and None <br />
D. Internal <br />
<b>Answer : B</b><br />
<br />
<b>22. Which of the following special symbol allowed in variable name ?</b><br />
A. * (astrisk)<br />
B. | (pipline)<br />
C. - (hyphen)<br />
D. _ (underscore)<br />
<b>Answer : D</b><br />
<br />
<b>23. By default a real number is treated as a </b><br />
A. float <br />
B. double <br />
C. long double<br />
D far double<br />
<b>Answer : B </b><br />
<br />
<b>24. A long double cand be used if range of a double is not enough to accommodate a real number.</b><br />
A. True <br />
B. False <br />
<b>Answer : A </b><br />
<br />
<b>25. A float is 4 bytes wide , whereas a double is 8 bytes wide. </b><br />
A. True <br />
B. False <br />
<b>Answer : A </b><br />
<br />
<b>26. Range of float id -2.25e-308 to 2.25e+308 </b><br />
A. True <br />
B. False <br />
<b>Answer : B</b><br />
<br />
<b>27. Which of the following is integral data type ?</b><br />
A. void<br />
B. Char<br />
E. float <br />
D. double<br />
<b>Answer : B</b><br />
<br />
<b>28. What is the range of signed int data type in that compiler in which size of int is two byte </b><br />
A. -255 to 255<br />
B. - 32767 to 32767<br />
C. -32768 to 32768<br />
D. -32768 to 32767<br />
<b>Answer : D</b><br />
<br />
<b>29. What is size of genric pointer in c? </b><br />
A. 0<br />
B. 1<br />
<b>C. 2</b><br />
D. Null<br />
<b></b><br />
<b>Answer : C</b><br />
<b><br />
</b><br />
<b></b><br />
<br />
<br />
</div>AMJAD KHANhttp://www.blogger.com/profile/05053334007721250279noreply@blogger.com0tag:blogger.com,1999:blog-8045866820531095476.post-26227886753798332362012-01-30T20:43:00.000-08:002012-01-30T20:43:11.192-08:00Objective Question of C Introduction<div dir="ltr" style="text-align: left;" trbidi="on"><strong>11. Which escape character can be used to begin a new line C?</strong><br />
A. \a<br />
B. \b<br />
C. \m<br />
D. \n<br />
<strong>Answer : </strong><br />
<br />
<strong>12. Which excape character can be to beep from speaker in C?A. \a</strong><br />
<strong>B. \b</strong><br />
<strong>C. \m</strong><br />
<strong>D. \n</strong><br />
<strong>Answer : </strong><br />
<br />
<strong>13. Character constants should be enclosed between__</strong><br />
A. Single Quotes <br />
B. Double Quotes <br />
C. Both a and b<br />
D. None of these<br />
<strong>Answer :</strong><br />
<br />
<strong>14. String constants should be enclosed between __</strong><br />
A. Single Quotes <br />
B. Double Quotes <br />
C. Both a and b<br />
D. None of these<br />
<strong>Answer :</strong><br />
<br />
<strong>15. Which of the follwing is invalid ?</strong><br />
A.''<br />
B." "<br />
C.'a'<br />
D. 'abc'<br />
<strong>Answer :</strong><br />
<br />
<strong>16. The maxiumum length of a variable in C is ___ </strong><br />
A. 8<br />
B. 16<br />
C. 32<br />
D. 64<br />
<strong>Answer : </strong><br />
<br />
<strong>17. What will be the maximum size of a float variable ?</strong><br />
A. 1 byte <br />
B. 2 bytes <br />
C. 4 bytes<br />
D. 8 bytes<br />
Answer :<br />
<br />
18. What will be the maximum size of a double variable ?<br />
A. 1 byte <br />
B. 4 bytes <br />
C. 8bytes<br />
D. 16 bytes<br />
Answer :<br />
<br />
19. A declaration float a, b; occupies ___ of memory <br />
A. 1 byte <br />
B. 4 bytes <br />
C. 8 bytes<br />
D. 16 bytes<br />
Answer :<br />
<br />
20.The size of a String variable is <br />
A. 1 byte <br />
B. 8 bytes <br />
C. 16 bytes<br />
D. None of these <br />
Answer :</div>AMJAD KHANhttp://www.blogger.com/profile/05053334007721250279noreply@blogger.com0tag:blogger.com,1999:blog-8045866820531095476.post-70737312105265384432012-01-30T20:20:00.000-08:002012-01-30T20:20:56.462-08:00Objective Question C Introduction<div dir="ltr" style="text-align: left;" trbidi="on"><b>1. Which of the following langauge is predecessor to C Programming Language ?</b><br />
<strong>(A) </strong>A.<br />
(B) B<br />
(C) BCPL<br />
(D) C++<br />
<strong>Answer : </strong><br />
<br />
<strong>2. C pogramming language was developed by </strong><br />
A. Dennis Ritchie <br />
B. Ken Thompson <br />
C. Bill Gates <br />
D. Peter Norton <br />
<strong>Answer : </strong><br />
<br />
<strong>3. C programming language was developed by </strong><br />
A. 1970 <br />
B. 1972 <br />
C. 1976 <br />
D. 1980<br />
<strong>Answer :</strong><br />
<br />
<strong>4. C is a -------- language </strong><br />
A. High Level <br />
B. Low Level<br />
C. Middle Level<br />
D. Machine Level<br />
<strong>Answer :</strong><br />
<br />
<strong>5. C language is available for which of the following Operating Systgem ?</strong><br />
A. Dos <br />
B. Windows <br />
C. Unix <br />
D. All of these<br />
<br />
6. Which of the following symbol is used to denote a pre-processor statement ?<br />
A. !<br />
B. #<br />
C. ~<br />
D, ;<br />
<strong>Answer : </strong><br />
<br />
<strong>7. Which of the following is a Scalar Data type </strong><br />
A. Float <br />
B. Union <br />
C. Array <br />
D. Pointer<br />
<strong>Answer :</strong><br />
<br />
<strong>8. Which of the following are tokens in C?</strong><br />
A. Keywords <br />
B. Varables <br />
C. Constants <br />
D. All of the above<br />
<strong>Answer : </strong><br />
<br />
<strong>9. What is the valid range of numbers for int type of data ?</strong><br />
A. 0 to 256 <br />
B. -32768 to +32767 <br />
C. -65536 to +65536 <br />
D. No specific Range<br />
<strong>Answer :</strong><br />
<br />
<strong>10. Which symbol is used as a statement terminator in C? </strong><br />
A. !<br />
B. #<br />
C. ~<br />
D, ;<br />
<strong>Answer : </strong><br />
</div>AMJAD KHANhttp://www.blogger.com/profile/05053334007721250279noreply@blogger.com0tag:blogger.com,1999:blog-8045866820531095476.post-51058821053436488132012-01-24T19:49:00.000-08:002012-01-25T22:25:44.483-08:00Ultimate GK Guide for Computer Exam<div dir="ltr" style="text-align: left;" trbidi="on">1. UNIVAC is <br />
a. Universal Automatic Computer <br />
b. Universal Array Computer<br />
c. Unique Automatic computer<br />
d. Unvalued Automatic Computer<br />
Answer <br />
<form><input type="button" VALUE="Click Here" onClick="alert('(A) Universal Automatic Computer!')"><br />
</form>2. ALU is <br />
a. Arithmetic Logic Unit<br />
b. Array Logic Unit <br />
c. Application Logic Unit<br />
d. None of above<br />
Answer :<br />
<form><input type="button" VALUE="Click Here" onClick="alert('(A) Arithmetic Logic Unit!')"><br />
</form><br />
3. VGA is <br />
a. Video Graphics Array <br />
b. Visual Graphics Array <br />
c. Volatile Graphics Array<br />
d. Video Graphics Adapter<br />
Answer <br />
<form><input type="button" VALUE="Click Here" onClick="alert('(D) Video Graphics Adapter!')"><br />
</form>4. MSI stand for <br />
a. Medium Scale Intergrated Circuits <br />
b. Medium System Integrated Circuits <br />
c. Medium Scale Intelligen Circuit <br />
d. Medium System Intelligent Circuit<br />
Answer :<br />
<form><input type="button" VALUE="Click Here" onClick="alert('(A) Medium Scale Intergrated Circuits !')"><br />
</form><br />
5. The first Computer introduced in Nepal was <br />
a. IBM 1400<br />
b. IBM 1401<br />
c, IBM 1402<br />
d. IBM 1403<br />
answer :<br />
<form><input type="button" VALUE="Click Here" onClick="alert('(B) IBM 1401 !')"><br />
</form><br />
</div>AMJAD KHANhttp://www.blogger.com/profile/05053334007721250279noreply@blogger.com0