My gut reaction would be to go with the Nexus 7. Unless you're doing something specifically that requires mobile data or you're planning on switching phones it's probably not going to be worth activating another line to throw a sim in the Nexus 4.
If it's a development class, though, use whatever is closest to whatever they'll be teaching with. Doing your layout for a tablet when everyone else is working with phones or vice versa might be a little cumbersome if you're just getting started.