Ah, the old “me/I” issue. I have heard something like this out of people: “Jack and I’s hair was too long so we got haircuts.” How about “Jack’s and my hair”, or even more simply, “our hair”.
As far as the other examples go,I was taught this way: “The teacher gave homework to everyone but Jack and I” Now take Jack out of the sentence. “The teacher gave homework to everyone but I.” Now try it the other way: “The teacher gave homework to everyone but Jack and me.” Again, remove Jack from the sentence. “The teacher gave homework to everyone but me.” Which one sounds better? In this example, “me” is correct.