Stars versus hashes
A string contains only * and # characters. Print the number of * minus the number of #.
Reported in: TCS NQT (Sep 2023) (memory-based)
Input
One line: the string.
Output
One integer (may be negative).
Constraints
1 ≤ length ≤ 10^5.
Example 1
Input:
###***#**
Output:
1Example 2
Input:
##
Output:
-2Hint: Count each character once.