TEMA

só dar presentation error 10% n consigo achar

gpereira30 preguntado 3 years ago

import java.io.IOException; import java.util.Scanner;

public class Main {

public static void main(String[] args) throws IOException {

    Scanner scan = new Scanner(System.in);
     float x = scan.nextFloat();
     float y = scan.nextFloat();
     if(x == 0.0 && y == 0.0)
     System.out.println("Origem");
     else 
         if(x == 0.0) 
             System.out.println("Eixo y");
         else
             if(y == 0.0)
             System.out.println("Eixo x");
             else
              if(x > 0.0 && y > 0.0)
             System.out.println("Q1");
               else
                if(x < 0.0 && y > 0.0)
                 System.out.println("Q2");
                else
                 if(x > 0.0 && y < 0.0)
                     System.out.println("Q4");
                 else
                     if(x < 0.0 && y < 0.0)
                         System.out.println("Q3");

}

}

Este tema fue resuelto y no puede recibir nuevas respuestas.

  • GabrielMartins respondido 3 years ago

    Em Eixo X e Eixo Y o x e o y tem que ser em maiúsculo.