adding more scala code