Thread: I dont understand this quiz question. Can someone elaborate?

  1. #1
    Registered User
    Join Date
    Mar 2018
    Posts
    6

    I dont understand this quiz question. Can someone elaborate?

    I understand that you can have statements like (5>7) and it would be the same as 0 because it is false but how can you have a statement like (5||7) What does this even mean?

    I dont understand this quiz question. Can someone elaborate?-qq-jpg

  2. #2
    and the hat of int overfl Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    39,659
    Why not create a simple program, type in the expression and work it out?

    Everything to the right of 6 evaluates to 0 by the way.
    n < n is always false (ie zero)
    Anything multiplied by zero is zero
    If either size of && is zero, the whole thing is zero.

    And so on.
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.

  3. #3
    Registered User
    Join Date
    Oct 2006
    Posts
    3,445
    Do you understand the meaning of boolean logic operators? If they're quizzing you about it, they must have mentioned it at some point in the course thus far.
    What can this strange device be?
    When I touch it, it gives forth a sound
    It's got wires that vibrate and give music
    What can this thing be that I found?

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. need help dont understand
    By txfog in forum C++ Programming
    Replies: 6
    Last Post: 06-14-2013, 07:38 AM
  2. i dont understand this question i got.
    By cfrye1990 in forum C++ Programming
    Replies: 4
    Last Post: 09-26-2009, 08:40 PM
  3. Question i dont understand
    By muran_pling in forum C++ Programming
    Replies: 4
    Last Post: 06-03-2007, 06:22 AM
  4. What I dont understand...
    By nomi in forum C# Programming
    Replies: 7
    Last Post: 01-20-2004, 02:00 AM
  5. I dont understand mega quiz question 14
    By stupid_mutt in forum A Brief History of Cprogramming.com
    Replies: 5
    Last Post: 09-30-2001, 02:03 AM

Tags for this Thread