import java.util.*;
public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		String eat = sc.next();
		System.out.println((eat.length() - eat.replace("+", "").length()) * 2 - 4);
	}
} import java.util.*; util.* java public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		String eat = sc.next();
		System.out.println((eat.length() - eat.replace("+", "").length()) * 2 - 4);
	}
} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		String eat = sc.next();
		System.out.println((eat.length() - eat.replace("+", "").length()) * 2 - 4);
	} main {
		Scanner sc = new Scanner(System.in);
		String eat = sc.next();
		System.out.println((eat.length() - eat.replace("+", "").length()) * 2 - 4);
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) String eat = sc.next(); eat sc.next() sc.next sc System.out.println((eat.length() - eat.replace("+", "").length()) * 2 - 4) System.out.println System.out System System.out (eat.length() - eat.replace("+", "").length()) * 2 - 4 (eat.length() - eat.replace("+", "").length()) * 2 (eat.length() - eat.replace("+", "").length()) eat.length() eat.length eat eat.replace("+", "").length() eat.replace("+", "").length eat.replace("+", "") eat.replace eat "+" "" 2 4 String[] args args public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		String eat = sc.next();
		System.out.println((eat.length() - eat.replace("+", "").length()) * 2 - 4);
	}
} public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		String eat = sc.next();
		System.out.println((eat.length() - eat.replace("+", "").length()) * 2 - 4);
	}
} Main
import java.util.*;
public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		String eat = sc.next();
		System.out.println((eat.length() - eat.replace("+", "").length()) * 2 - 4);
	}
}