import java.util.Scanner

object Main {
  def main(args: Array[String]): Unit = {
    //nextLineとnextを同時に使ったら死ぬ
    val sc = new Scanner(System.in)
    val n = sc.nextInt()
    val as = Array.fill(n)(sc.nextLong())

    val absArray = as.map(math.abs)
    val absMin = absArray.min
    val amountOfNegative = as.count(_ < 0)

    val ans = if (amountOfNegative % 2 == 0) {
      absArray.sum
    } else {
      absArray.sum - absMin * 2
    }

    println(ans)
  }

  def debug(args: Any*): Unit = {
    Console.err.println(args.mkString(" "))
  }
}
