“c Programação TRINARE se” Respostas de código

c Programação TRINARE se

#include <stdio.h>

int main() {
  int age;

  // take input from users
  printf("Enter your age: ");
  scanf("%d", &age);

  // ternary operator to find if a person can vote or not
  (age >= 18) ? printf("You can vote") : printf("You cannot vote");

  return 0;
}
Oren Gruber

c Programação TRINARE se

testCondition ? expression1 : expression 2;
Oren Gruber

Respostas semelhantes a “c Programação TRINARE se”

Perguntas semelhantes a “c Programação TRINARE se”

Mais respostas relacionadas para “c Programação TRINARE se” em C

Procure respostas de código populares por idioma

Procurar outros idiomas de código