Trans World Airlines and American Airlines made a joint offer yesterday to buy Pan American World Airways. If successful, they will divide up the bankrupt air carrier.The joint bid by TWA and American is said to be an effort to derail an earlier offer made by Delta Air Lines to buy several of Pan Am's operations. Earlier this month Pan Am had accepted Delta's offer to buy its African, Asian, and European routes, the Boston-New York-Washington shuttle, and 45 planes for $260 million. But because Pan Am has filed for bankruptcy, the decision is up to the federal court. The TWA/American offer amounts to $310 million.