object Main extends App {

  import scala.io.StdIn._
  import scala.math._

  val Array(width, height, w, h, x, y) = readLine.trim.split(' ').map(_.toInt)
  val daunats = Section(-height, height, width, -width)
  val ate = Section(y - h, y + h, x + w, x - w)
  daunats.intersection(ate) match {
    case None ⇒ println(1)
    case Some(s@Section(b,u,r,l)) ⇒
      println((r + l).toDouble / (b + u).toDouble)
  }
  case class Section(bottom: Int, up: Int, right: Int, left: Int){
    def verticalRange: Range = Range(bottom, up)
    def horizontalRange: Range = Range(left, right)
    def intersection(that: Section): Option[Section] = {
      verticalRange.intersection(that.verticalRange).flatMap{vRange ⇒
        horizontalRange.intersection(that.horizontalRange).map{hRange ⇒ Section(hRange.from, hRange.to, vRange.to, vRange.from)}
      }
    }
  }
  case class Range(from: Int, to: Int){
    def intersection(that: Range): Option[Range] = {
      if (to < that.from || from > that.to) None
      else Some(Range(math.max(from, that.from), math.min(to, that.to)))
    }
  }
  implicit class Extension[T](val value :T){
    def also(func: T ⇒ Unit): T = {
      func(value)
      value
    }
    def let[R](func: T ⇒ R): R = func(value)
  }
}
