added code to find SS index