What is the Difference between imperative and interrogative
code?

Answer Posted / nayana

Some methods return values or provide information back to
the calling code. These are called interrogative methods.
Others, called imperative methods, just perform a service
and return nothing to the calling code.
In VB.NET, methods are implemented using Sub (for
imperative methods) or Function (for interrogative methods)
routines within the class module that defines our object.
Sub routines may accept parameters, but they don't return
any result value when they are complete. Function routines
can also accept parameters, and they always generate a
result value that can be used by the calling code.

Is This Answer Correct ?    26 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Can the accessibility of a type member be greater than the accessibility of its containing type?

564


Can you prevent a class from being instantiated?

596


What is reflection in c#?

496


Why we use get set property in c#?

476


Can we have static indexer in c#?

495






What is default value of bool in c#?

522


What does m mean in decimal c#?

498


What are the types of comment in c# with examples?

479


What is hashmap in c#?

480


What is int64 in c#?

497


Is constructor a static method?

495


How to find the current application file path while runtime?

505


How do you declare a method in c#?

495


What are some of the commonly used commands in sqlcommand?

494


How do I join one form to another in c#?

466