package students;
import java.math.*;
public class Test {
public static void main(String [] args){
Thing a=new Stone();
a.throwThing(20,12);
}
}
class Stone implements Thing{
public void throwThing(double vv,double hh){
double dis=Math.sqrt(vv*2*hh/10);
System.out.println("石头"+dis);
}
}
class Paper implements Thing{
public void throwThing(double vv,double hh){
double dis=Math.sqrt(vv*2*hh/10);
System.out.println("纸团"+dis);
}
}
//接口是
public interface Thing{
public void throwThing(double a,double b);
}