import java.util.Scanner

object Main {
	
	@JvmStatic
	fun main(args: Array<String>) {
		val scanner = Scanner(System.`in`)
		val inputString = scanner.next()
		val answer = inputString.replace("-","").length * 2 - 4
		print(answer)
		scanner.close()
	}
	
}