Logical functions, Computer Engineering

Assignment Help:

Logical functions

  We have discussed the If, 'While and For' Statements, and have used expressions within our syntax i.e.
 
        If ( expression)
          Statement 1;
        else
          Statement 2;
 
        do
        statement;
        while (expression);
 
        for (init;expression;alter)
        statement;
 
        while ( expression)
        statement;

We tended to restrict ourselves to simple expression i.e A == 5 etc. This is a simplification of what an expression really is. The equality sign indicates a logical identity i.e. true or false. Many other logical expressions could yield true or false .The most common ones are AND '&&', OR  '||' and NOT '!' , these behave identical to there truth table counterparts .  Therefore a valid expression could be

        (age > 40) &&( term < 10) 
  
  If age is greater than 40 and term is less than 10 then it is true or false 
 
        (age > 40) || (term <10)
  If age is greater than 40 or term is less than 10 then it is true or false 
 
        (age !> 40) || (term <10)
 
  If age is not greater than 40 or term is less than 10 then it is true or false


Related Discussions:- Logical functions

Determine waiting and average waiting time of CPU, CPU burst time indicates...

CPU burst time indicates the time, the process needs the CPU. The following are the set of processes with their respective CPU burst time     (in milliseconds). Process

Generalization-specialization(DBMS), Design a generalization-specialization...

Design a generalization-specialization hierarchy for a motor vehicle sales company. The company sells motorcyles,passenger cars,vans,and buses.justify your placement of attributes

Define the don''t care states - simplifying k maps, Define the Don't Care S...

Define the Don't Care States - Simplifying K Maps? The Truth table specifications for a logic function may not to include all possible combinations of the input binary digits for

Signaling - universal serial bus , Signaling - Universal Serial Bus: U...

Signaling - Universal Serial Bus: USB supports following signaling rates: o   A low speed rate of 1.5 Mbit/s is defined by USB 1.0. This is so much similar to "full speed"

Priority interrupt and synchronous bus, What is a Priority Interrupt? A...

What is a Priority Interrupt? Ans: A priority interrupt is a type of interrupt that establishes a priority over the many sources to determine which condition is to be serviced

What are desirable features of an electronic market place, What are the des...

What are the desirable features of an Electronic Market Place? Features of an Electronic Market Place: 1. Its electronic and business center is not a physical building qu

Static or dynamic - artificial intelligence, Static or Dynamic - artificial...

Static or Dynamic - artificial intelligence An environment is static if it doesn't change while an agent's program is making the decision about how to act. When programming ag

Define hypertext verses hypermedia briefly, Define Hypertext verses Hyperme...

Define Hypertext verses Hypermedia briefly. Hypertext is fundamentally the same as regular text- this can be stored, read, searched or edited along with a significant exception

What are the two types of branch prediction techniques, What are the two ty...

What are the two types of branch prediction techniques available?  The two types of branch prediction methods are  1) Static branch prediction  2) Dynamic branch predicti

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd