Technology Questions

Q:

What are the advantages of using friend classes?

Answer

- Friend classes are useful when a class wants to hide features from users which are needed only by another, tightly coupled class. 


- Implementation details can be kept safe by providing friend status to a tightly cohesive class.

Report Error

View answer Workspace Report Error Discuss

Subject: C++

0 3761
Q:

Which of the following are valied?

A) A class can extend any number of classes simulteneously B) A class can implement only one interface at a time
C) A class can extend other class or can implement interface but not both simulteneously D) None of the above
 
Answer & Explanation Answer: D) None of the above

Explanation:

A is wrong because a class can extend nly one class .B is wrong because a class can implement any number of interfaces.C is wronb because both can can be done simulteneously.So, D is correct

Report Error

View Answer Report Error Discuss

Filed Under: Java
Job Role: IT Trainer

1 3756
Q:

Default constructor accepts how many arguments?

A) one B) two
C) three D) None
 
Answer & Explanation Answer: D) None

Explanation:

Default constructors has no arguments

Report Error

View Answer Report Error Discuss

Filed Under: C++

1 3753
Q:

How can we distinguish between an online and batch program in IMS environment?

Answer

If in application program IO-PCB is there then it is a online program. In ENTRY statement IO-PCB must be listed first and then DB-PCB.

Report Error

View answer Workspace Report Error Discuss

1 3735
Q:

When will you define a method as static?

Answer When a method needs to be accessed even before the creation of the object of the class then we should declare the method as static.
Report Error

View answer Workspace Report Error Discuss

Subject: Java

0 3726
Q:

What is the use of Namespace?

A) To encapsulate the data B) To structure a program into logical units.
C) Both a and b D) none of these
 
Answer & Explanation Answer: B) To structure a program into logical units.

Explanation:

The main aim of the namespace is to understand the logical units of the program and to make the program so robust.

Report Error

View Answer Report Error Discuss

Filed Under: C++

1 3724
Q:

Difference between Embeded SQL and Dynamic SQL?

Answer

Static (embedded) SQL:


1.In static SQL how database will be accessed is predetermined in the embedded SQL statement.


2.It is more swift and efficient.


3.SQL statements are compiled at compile time.


4.Parsing, validation, optimization, and generation of application plan are done at compile time.


5.It is generally used for situations where data is distributed uniformly.


6.EXECUTE IMMEDIATE, EXECUTE and PREPARE statements are not used.


7. It is less flexible 


 


Dynamic (interactive) SQL:


1.In dynamic SQL, how database will be accessed is determined at run time.


2.It is less swift and efficient.


3.SQL statements are compiled at run time.


4.Parsing, validation, optimization, and generation of application plan are done at run time.


5.It is generally used for situations where data is distributed non-uniformly.


6.EXECUTE IMMEDIATE, EXECUTE and PREPARE statements are used.


7.It is more flexible.

Report Error

View answer Workspace Report Error Discuss

0 3709
Q:

What is the difference between _construct() and _destruct() methods in php?

Answer

These two methods are bulid-in methods  in php. with  construct() we can overwride the parent class method. The inverse of the __construct() PHP capacity while making another class, is the __destruct() technique. The __destruct() technique will consequently keep running, after you've completed with the PHP class.

Report Error

View answer Workspace Report Error Discuss

Subject: PHP
Job Role: Software Architect

1 3700