InterviewBit Academy is now Scaler!
InterviewBit Academy is now Scaler Academy!

Number of Hosts per Subnet

Given a string A representing valid subnet mask. Find the number of hosts possible.

Input Format

The only argument given is string A.

Output Format

Return the number of possible hosts.

For Example

Input 1:
    A = ""
Output 1:

Input 2:
    A = ""
Output 2:
NOTE: You only need to implement the given function. Do not read input, instead use the arguments to the function. Do not print the output, instead return values as specified. Still have a doubt? Checkout Sample Codes for more details.
Start solving Number of Hosts per Subnet on Interview Code Editor
Sign Up
to access hints and editorial solutions for Number of Hosts per Subnet


Click here to start solving coding interview questions