#!/usr/bin/env python2

import sys

version=sys.argv[1]

i = 0

for c in version:
    if c >= '0' and c <= '9':
        break
    i = i + 1

micro = 0

try:
    major, minor, micro = version[i:].split(".")
except ValueError:
    major, minor = version[i:].split(".")

print int(major) * 100 + int(minor) * 10 + int(micro)
