--%>

Explain Counters

Counter variables are commonly used in many computer applications for different purposes. Here is a typical example where a variable is used to measures the progress of some activity of interest:

1146_counter1.jpg

If the exact value of the progress variable or the entire range of its values is not really required for checking the property of interest, then the use of this variable can cause unnecessary (potentially infinite) state space expansion. In this case, the progress variable can be reduced to a Boolean variable:

80_counter2.jpg

This modification immediately cuts down the number of states that need to be explored for this piece of code from ((2*MAXINT)+1)2 to only two possibilities: the progress variable taking only the value of true or false. Such small modifications can lead to exponential improvements in memory and time for a model checker.

   Related Questions in Programming Languages

  • Q : Define the term Boot Boot: Whenever a

    Boot: Whenever a computer is switched on it is said to be `boot up'. This word comes from the phrase, “Pulling yourself up by your bootstraps”. Before a computer is ready to be utilized, it should load the programs which it requires from i

  • Q : Define Object-oriented language

    Object-oriented language: Programming languages like Java and C++ which permit the solution to a trouble to be stated in terms of objects that belong to the classes.

  • Q : Define the term Writer class Writer

    Writer class: It is a sub class of the Writer abstract, stated in the java.io package. The writer classes translate output from Unicode to the host-dependent character set encoding.

  • Q : Persistent and non-persistent objects

    Illustrate the difference between persistent and non-persistent objects in the programming?

  • Q : Define the term Marking interface

    Define the term Marking interface: It is an interface with no methods.

  • Q : What is MIME MIME : Multipurpose

    MIME: Multipurpose Internet Mail Extensions (abbreviated as MIME) are rules which make it possible to utilize electronic mail to send content other than the simple text.

  • Q : Define the term createWindow object

    Define the term createWindow object? Answer: reateWindow() physically makes the Window in memory  based upon the earlier registered WND

  • Q : Retrieve the text for ORA-12705 Normal

    Normal 0 false false

  • Q : How can I check while a web page

    How can I check while a web page contains exact text?

  • Q : Define the term Catching exceptions

    Catching exceptions: Exceptions are caught in the catch clause of the try statement. Catching an exception provides the program a chance to recover from the trouble or attempt a repair for whatsoever caused it.