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

What is gimps native graphics file format, XCF is GIMP's "native" format. T...

XCF is GIMP's "native" format. This will preserve all information about an image, having the layers.

Assembly program, where do i get some sample assembly projects (with coding...

where do i get some sample assembly projects (with coding included)?

Explain memory write operation, Q. Explain Memory Write operation? Memo...

Q. Explain Memory Write operation? Memory write operation transfers content of a data register to a memory word M selected by the address. Presume that data of register R1 is t

Learning weights in perceptrons, Learning Weights in Perceptrons - Artifici...

Learning Weights in Perceptrons - Artificial neural network In detail we will look at the learning method for weights in multi-layer networks next chapter. The following descri

Hrm, hrm digrams

hrm digrams

Characteristics of storage - computer architecture, Characteristics of comp...

Characteristics of computer storage: Storage technologies at all of levels of the storage hierarchy may be distinguished by evaluating particular core characteristics and alon

Operation of micro controller, Consider the hardware design as shown. Withi...

Consider the hardware design as shown. Within the target system the EPROM would contain the hex data as shown below   Address  Assembly code   8000             86   8001

What is the role of a controller in an mvc application, The controller resp...

The controller responds to user interactions, with the application, by selecting the act method to implement and also selecting the view to render.

E-commerce in the market, Considering the fact that a lot of research has b...

Considering the fact that a lot of research has been done concerning e-commerce, what has been brought in this work is that there has been a lot of facts, studies, and experiments.

What are the modes in which any update tasks work, What are the modes in wh...

What are the modes in which any update tasks work? Synchronous and Asynchronous.

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