Sylvia buys a case of water that contains 24 bottles and sells x number of bottles to her co-workers. Sam buys a case of water than contains 36 bottles and sells three times as they bottles as Sylvia sold to his co-workers. How many bottles of water did Sylvia sell if they ended up with the same number of bottles of water left over?