I don't mind visitors doing homework, which as you say, evaporates if they leave it behind. It just annoys me when I have just told one of my resident sims to serve a meal, and some visitor just decides to stick their homework on the only available table. Doesn't matter in dorms, but I tend to use houses more. I only really use dorms for times when I have no empty houses cheap enough, or when I want a sim to go to college and I want the goodbye Dad/Mum scene to play! But when my sims are allowed parties, it's when they have their own home.
Ahh... I see. Well, if you use my mod, (and I forgot to mention this in the first post and the README), visitors pretty much won't be able to do assignments on any other lot except for Community Lots. I did that because Community Lots don't really save (unless you actually enable the UI tools and save it) so the homework will disappear upon reload. I just didn't want any kind of useless clutter from visitors who may never be invited over again. Like, if I greeted a stranger "off the street" just so I could interact with them. But then decide that I never want to see that sim again (especially if I find out that they don't get along very well with the sims that live on that lot). Then I wouldn't want them to start their stupid homeworks and clutter up my lot. Of course, I started modding this before finding out that visitor homeworks disappear anyways.
If I feel up to it... I could look into making it a bit more complex as far as this goes. What I could do, is for visitors on non Dorm or non Community lots, put a search for assignments that belong to sims who live on that lot and check if they are "In Use" which would indicate that a sim who lives on that lot is doing assignment. Only in this case, would visitor sims be allowed to do assignment, because it could mean that they have been invited over for a "study date" or something like that.
As for preventing the use of tables, that may be a bit more complicated for me. I'll have to take a look into that as well.
Ste