object Main extends App {
  def calc(formula: List[(Char, Char)]): Int =
    formula.foldLeft(0) { case (acc, (op, number)) =>
      val int = number.toString.toInt
      if (op == '+') acc + int else acc - int
    }

  val sc = new java.util.Scanner(System.in)
  val numbers = sc.next().toCharArray
  val calcPatterns = for {
    ab <- List('+', '-')
    bc <- List('+', '-')
    cd <- List('+', '-')
  } yield {
    List('+', ab, bc, cd)
  }
  calcPatterns
    .map(_.zip(numbers))
    .collectFirst {
      case formula if calc(formula) == 7 =>
        formula.flatMap {
          case (op, number) => List(op, number)
        }.mkString("", "", "=7").tail
    }
    .foreach(println)
}
