Logical functions, Computer Engineering

Logical functions

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

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

Posted Date: 4/15/2013 6:22:06 AM | Location : United States

Related Discussions:- Logical functions, Assignment Help, Ask Question on Logical functions, Get Answer, Expert's Help, Logical functions Discussions

Write discussion on Logical functions
Your posts are moderated
Related Questions
With reference to telephone traffic, explain the terms CCR. CCR: Call completion rate is explained as the ratio of the number of successful calls to the number of call attemp

Visibility. Controls should be clearly visible, so users can see the controls that are available to them. Visual feedback should also be clearly visible, so users can understand wh

Q. Illustrate about Packet switching? Packet switching is used to avoid long delays in transmitting data over the network. Packet switching is a technique that limits the amoun

Distributivity of Connectives : In our last analogy with arithmetic will involve a very well-technique need for playing around with algebraic properties. But assume there if w

what is opcode for addition and subtraction

Q. Explain the following: a) Gray code b) Parity code c) Overflow Q. Give the counting up to 30 in Base 5. Q. Convert (175.6)8 into Gray code and Excess-3 code.

Overriding tell us only the methods, but shadowing tells us the entire element.

Q. What is the working of domain expert? ANSWER: The domain expert is the person who gives the domain expertise in the form of problem-solving strategies.

Explain What is the difference among embedded systems and the system in which RTOS is running? Ans) Embedded system can have RTOS and cannot have also. It depends on the requi

What is critical section problem?  Consider a system having of 'n' processes. Each process has segment of code known as a critical section, in which the process may be changing