Ayúdanos a dar forma a GoConqr. ¿Qué deberíamos añadir?

Fichas

Conditional Operators and Statements

nini798 Inglés 21 fichas

Fichas del conjunto (21)

  1. 1==equals
  2. 2<=smaller than or equals to
  3. 3>=greater than or equal to
  4. 4!=does not equal
  5. 5<smaller than (exclusive)
  6. 6>greater than (exclusive)
  7. 7||or
  8. 8&&and
  9. 9syntax of an if/else statementif(condition)
    {
    statements;
    }
    else
    {
    statements;
    }
  10. 10Syntax of a switch & case statementswitch(variable){
    case value: statements;
    break; //optional
    case value: statements;
    ...
    }
  11. 11Which 'if' will the 'else' pair up with? if(statement){ if(statement){ else{ } } }if(statement){
    if(statement){ //this one
    else{
    }
    }
    }
  12. 12What data types will work with the variable creating a switch?int, byte, short, char, String (other types, but not very relevant to this class, are enumerated types and classes that "wrap" primitive data types, such as Integer, Byte, Short, Character)
  13. 13else statements pair up with:the closest if statement that's available. (not available means that the if statement is locked outside of brackets of another, outer 'if' statement. See example below:
    if(statement){ //locking bracket
    if(statement){
    }
    } //locking bracket
    else{ //outside of bracket
    }
  14. 14Optional statements added after an 'if' statementelse, else if
  15. 15syntax for a nested 'if' statementif(condition){
    if(condition){
    }
    }
  16. 16What is this equivalent to? !(A && B)!(A) || !(B)
  17. 17What is this equivalent to? !(A || B)!(A) && (B)
  18. 18De Morgan's Lawnot(A or B) == (not A) and (not B)
    as well as
    not(A and B) == (not A) or (not B)
  19. 19break statementexits a switch statement
  20. 20default statementused at the end of a switch statement, takes all values, implies that other cases weren't reached
  21. 21case groupsmultiple cases that all run the same statement in a switch

Información

Descripción
Flashcards for conditional and relational operators/statements in java
Creado por
nini798
Visitas
63
Etiquetas
javaconditionalrelational
Valoración

Escríbenos

¿Sobre qué es tu mensaje?

¿Qué deberíamos añadir?