What law does Mayella break? What social code does she violate? Which would most citizens of Maycomb consider the more serious crime and why?
Mayella commits perjury by giving a false testimony while on the witness stand during the Tom Robinson trial. Perjury is the intentional act of swearing a false oath during an official proceeding. Mayella commits perjury by falsely accusing Tom Robinson of assaulting and raping her. The truth is that Bob Ewell, Mayella's father, assaulted her after he witnessed his daughter kissing Tom Robinson.
Atticus elaborates on the strict social code that Mayella broke, which concern white women tempting black men, during his closing arguments. In 1930s Alabama, interracial relations were taboo, and it was considered an unspeakable act for a white woman to kiss a black man. When Mayella was caught making sexual advances towards Tom, her father assaulted her and she attempted to cover up her actions by falsely accusing Tom of raping her.
In my opinion, the racist citizens of Maycomb would view Mayella's sexual advances towards Tom to be the more serious crime. The prejudiced citizens would have been both disgusted and upset that a white woman would have tempted a black man because it challenges their traditional, racist views of how society should operate.
I think it is important to consider that a little more is going on than just lying under oath vs. a black man in contact with a white woman.
#1: She lies under oath because it is actually her father who is guilty here. Obviously we can't know if she does this to protect him or because she fears him. A little of both? This is almost forgivable by today's standards.
#2: She is not simply a white woman in contact with a black man. She makes sexual advances on Tom. She, in fact, kisses him. This is what is so shameful. And she does it because she is so lonely, dejected, insecure (something), that this is the only man she can get attention from. To Maycomb - it is shameful because he is a black man. But it it might also be considered shameful today because he is married.
Even by today's standards it is easy to see which "crime" would be considered more serious.
The law that Mayella breaks is the law against perjury. She gets up on the stand and tells a lie.
The social code that she breaks is the code against having black men and white women in contact with one another.
I think that it is quite clear that the people of Maycomb would consider the breaking of the social code to be much more serious. This is because their whole society is based on the separation of white and black people. By breaking that social rule, she is undermining the foundations of their social order. Lying in court does not do that.