Create a expand function in pairs.sc