Skip to content

Instantly share code, notes, and snippets.

@uncoded-ro
Last active January 13, 2020 04:53
Show Gist options
  • Save uncoded-ro/5188a2592336edc15b62ab24b4887369 to your computer and use it in GitHub Desktop.
Save uncoded-ro/5188a2592336edc15b62ab24b4887369 to your computer and use it in GitHub Desktop.
class OpCond {
public static void main(String[] args) {
int varsta = 15;
String tipPersoana;
tipPersoana = (varsta < 18) ? "adolescent" : "tanar";
System.out.println("Varsta " + varsta + " ani corespunde unui " + tipPersoana + ".");
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment