Java help, logical expressions

Asked

Viewed 16 times

-2

write a logical expression to determine whether a person is a voter or not. consider that they are voters, persons aged 16 or over

  • What mistake are you making, where is the code?

1 answer

1

Would this be:

if (idade >= 16) {
  System.out.println("apto a votar");
} else {
  System.out.println("inapto a votar");
}

Browser other questions tagged

You are not signed in. Login or sign up in order to post.