Use casting to integer and Option type implicitly