fork(1) download
  1. class Classe {
  2. void metodo(float x) {
  3. System.out.printf("Float %f\n", x);
  4. }
  5. void metodo(double x) {
  6. System.out.printf("Double %f\n", x);
  7. }
  8. }
  9.  
  10. class Ideone {
  11. public static void main(String args[]) {
  12. Classe classe = new Classe();
  13. classe.metodo(1);
  14. classe.metodo(1.0);
  15. classe.metodo(1.0f);
  16. }
  17. }
Success #stdin #stdout 0.12s 320576KB
stdin
Standard input is empty
stdout
Float 1.000000
Double 1.000000
Float 1.000000