Join Our Email Alerts-Subscribe
Important Note:Login & Check Your Email Inbox and Activate Confirmation Link



Enter Your Email :

Copyright Disclaimer:
Section 107 of the Copyright Act Fair Use Contents .
We are forwarding content link(s) from our website to content website & We are not serving any contents.
Main Source:Google.com.All the Content PDF link(s) is/are obtained from GoogleSearch
for the purpose of Education & Teaching Intention. Not for commercial purpose.
Technicalsymposium.com is not liable/responsible for any copyright issues.

Placement Materials & Answers-Free Download


Software Companies Placement Papers With Answers- Aspire-Free Download

1. What is abstract class?

Abstract cls contains abstract methods and abstract data members, abstract methods are methods with out definition. Abstract class can also contain non abstract methods ie., method with definition. We cannot create object for abstract cls. Abstract cls are inherited by derived classes and they should implement all the abstract methods of the inherited abstract class.

2. Why we cant create object for abstract class?

To create an object of any class its mandatory to know that how much memory required to load the class so in case of abstract class its can't be calculated for abstract members thats why we can't create object of Abstract class

An Abstract class is a partial implementation of a class. In other words, at least some of the operations or methods are implemented, but the full implementation is left up to an inherited class.

Without a full implementation, how could we instantiate the class? What if the client was to call one of the abstract (not defined) operations? Obviously, this would result in a failure.

3. What is Encapsulation?

Encapsulation is the process of grouping up of datamembers and member functions.

4. Give an Example for Encapsulation?

Class encapsulates data member and member function. These function and data members are inaccessible to outside environment.

5. Why java does not support multiple inheritances?

1) First reason is ambiguity around Diamond problem, consider a class A has foo() method and then B and C derived from A and has there own foo() implementation and now class D derive from B and C using multiple inheritance and if we refer just foo() compiler will not be able to decide which foo() it should invoke. This is also called Diamond problem because structure on this inheritance scenario is similar to 4 edge diamond, see below

A foo()

/ \

/ \

foo() B C foo()

\ /

\ /

D

foo()

2) Multiple inheritances does complicate the design and creates problem during casting, constructor chaining etc

6. When finally block will not be executed?

When try or catch block calls System.exit(), then finally block will not be executed.

If the jvm exits while the try or catch code is being executed, then the finally block may not execute. Likewise, if the thread executing the try or catch code is interrupted or killed, the finally block may not execute even though the application as a whole continues.

7. Programs: (Reverse the string without using inbuilt function)

void main()

{

char n[10];

int i=0,count=0;

cout<<"Enter the string";

gets(n);

while(n[i]!='\0')

{

count+=count;

n++;

}

while(count>=0)

{

cout<<n[count];

count--;

}

}

output:

SINDHU

UHDNIS

8. Program: (print triangle in following format)

format:

1

2 4

3 6 9

4 8 12 16

5 10 15 20 25

void main()

{

int n,c=1,k;

cout<<"Enter the limit ie the number of rows";

cin>>n; //here n=5;

for(int i=0;i<n;i++)

{

k=c;

for(j=0;j<=i;j++)

{

cout<<'\t'<<k;

k=k+c;

cout<<'\t';

}

cout<<'\n';

c++;

}

}

In a class composed of x girls and y boys what part of the class is composed of girls

A.y/(x + y)

B.x/xy

C.x/(x + y)

D.y/xy

Ans.C

10.What is the maximum number of half-pint bottles of cream that can be filled with a 4-gallon can of cream(2 pt.=1 qt. and 4 qt.=1 gal)

A.16

B.24

C.30

D.64

Ans.D </k;
</n;i++)
</n[count];

Source: Contents are provided by Technicalsymposium Google Group Members.
Disclaimer: All the above contents are provided by technicalsymposium.com Google Group members.
Further, this content is not intended to be used for commercial purpose. Technicalsymposium.com is not liable/responsible for any copyright issues.

Placement Papers & Answers PDF-Download



Aptitude & Placement Papers & Answers PDF



Technicalsymposium.com-All Study Materials PDF-Free Download







Technicalsymposium.com-Free Live Support-Chat with Our Experts

Official Contact: +91-9245556793 (Whatsapp Message / SMS / Voice Call)


Our Expert team is ready to answer all your questions immediately-Feel free to speak in Tamil/English.

(Example:Events info/Lecture Notes/Off-Campus & All Jobs/Projects & All education information)

Working hrs (IST): (Morning: 10:00AM-3:00 PM) and (Evening:5:00 PM to 10:00 PM)

All Latest Question & Answer Page (FAQ)-Click here