programming skill questions



 Basic Languages like c, c++, and java is act as an important platform for all coding developers in the scratch level. For most today all the company’s needed only the skilled people. The Skills are classified as Communication skills, Programming Skills, Technical Skills. In Which Programming Skill   plays a Major role for developing the code.

Programming skill questions are very much useful in terms of learning the basic languages like c, c++ , java .

Here the following questions which is often asked by the Interviewers. Bold Highlighted option is correct option for each following questions.

1. Which of the following type of class allows only one object of it to be created?
a) Virtual class   b) Abstract class   c) Singleton class  d) Friend class

2.which of the following is not the member of class?
a) static Function  b) Friend Function   c) const Function  d)virtual Function

3.Which of the following concepts means determining at runtime what method to invoke?
a)Data Hiding  b)Dynamic Typing  c) Dynamic binding  d) Dynamic loading

4. cout is a/an_____________
a)operator  b) Function  c)object  d)macro

5.Which of the following correctly describes overloading of functions?
a)Virtual polymorphism  b)Transient  polymorphism c)Ad-hoc polymorphism
d)pseudo polymorphism

6.How “Late Binding” is implemented in c++?
a)Using c++tables
b)Using  Virtual tables
c)Using  Indexed virtual tables
d)Using polymorphic tables
7.Which of the following problem causes an exception?
a)Missing semicolon in statement in main().
b)A problem in calling function
c)A syntax error
d)A run-time error

8. Why We use array as a parameter of main method  ?
a) It is syntax
b) Can store multiple values
c) Both of above
d) None of above
9. Runnable is
a)class
b) Method
c) Variable
d)Interface
10.Suspend thread can be revived by using
a)start()method
b)Suspend() method
c)resume() method
d).yield() method

11.All raw data types should be read and uploaded to the database as an array of
a)int
b)char
c)Boolean
d)byte
12.The Class java.sql.Timestamp is associated with
a)java.util.Time
b)java.sql.Time
c)java.util.Date
d)None of  above
13.Object which can store group of other objects is called
a)Collection object
b)Java object
c)Package
d)Wrapper
14.Minimum threads in a program are
a)1
b)2
c)5
d)Many
15.JAR file contains compressed version of
a)java file
b)class file
c)jsp file
d)None of above
16. How many keywords are there in 'C' ?

a) 24
b)32
c) 44
d) 52

17. What will be the output of the following statement ?

/* /* printf("hello"); */ */

a) hello
b) no output
c) error
d) "hello"

18. What will be the output of the following arithmetic expression ?

5+3*2%10-8*6

a) -37
b) -42
c) -32
d) -28
19. What will be the output of the following statements ?

int a = 1, b = 2 , c; c = = a = = b; printf("%d",c);

a) 0
b) 1
c) error
d) garbage value
20. What will be the output of the following program ?

#include<stdio.h>
#include<math.h>
void main()
{ float a = 3.26; printf("%f",ceil(a)); }

a) 4.0
b) 3.0
c) 3.2
d) none of these

21. What will be the output of the following program ?

#include<stdio.h>
void main()
{ extern int x; printf("%d",x); }int x = 10;

a) error
b) 0
c) garbage value
d) 10



21. What will be the output of the following program ?

#include<stdio.h>
void main()
{ struct p
{
int a,c ; float b;
}d = {1};
printf("%d%d%f",d.a,d.c,d.b);
}

a) garbage value
b) 100.0
c) error
d) 000.0

22.What will be the output of the following statements ?

int *a; float far *b; char huge*c

printf("%d,%d,%d",sizeof(a),sizeof(b),sizeof(c));

a) 222
b) 444
c) 244
d) 224

21. What will be the output of the following statement ?

int a=10; printf("%d &i",a,10);

a) error
b) 10
c) 10 10
d) none of these

22.Which of the following definition is incorrect ?

a) long int;
b) float double;
c) float real;
d) long long;

23.What will be the output of the following program ?

#include<stdio.h>
void main()
{ int a = 2;
switch(a)
{ case 1:
printf("goodbye"); break;
case 2:
continue;
case 3:
printf("bye");
}
}

a) error
b) goodbye
c) bye
d) byegoodbye
24.What will be the output of following statements ?

char x[ ] = "hello hi"; printf("%d%d",sizeof(*x),sizeof(x));

a) 88
b) 18
c) 29
d) 19

25. What is the range of "real constants" in 'C'?

a) -3.8 x 10 38 to 3.8 x 10 38
b) -34E37 to 34E37
c) -6.4 x 10 34 to 6.4 x 10 34
d) -68E33 to 68E33




Share this post
  • Share to Facebook
  • Share to Twitter
  • Share to Google+
  • Share to Stumble Upon
  • Share to Evernote
  • Share to Blogger
  • Share to Email
  • Share to Yahoo Messenger
  • More...

0 comments:

Post a Comment