lundi 30 octobre 2017

Is this an example of a ternary condition or is it something unrelated / different, i = j = 0?

I recently learned about ternary condition (specifically using : and ?, colons and questions marks, to create a condition that uses the question mark as an if statement, and the semicolon as a else statement. I recently came across the statement, i = j = 0. Is this the same type of condition? Is the statement saying:

if j = 0
{
    i == j
}
else
{
    i != j
}

Or is it referring to something different that I haven't learned yet, if so, please state what the statements purpose is, and how it works. Additionally, I couldn't find this exact question on the site, but if this is a duplicate, or if there is another website that you could refer we to that answers the question, I would be happy to delete to question, and then I would go and see what that website's information is. I would appreciate your input though, as I believe that this site does the best of any other site as for as explanations. Thank you all for your help! If you have any questions fell free to ask in the comments!

Aucun commentaire:

Enregistrer un commentaire