Function to calculate speed
static double cal_speed ( double dist , double time ) { System . out . print ( " Distance ( km ) : " + dist) ; System . out . print ( " Time ( hr ) : " + time) ; return dist / time ; }