Gang bosses have introduced the written tests for their subordinates since the Anti-Organised Crime Law was revised last year, making the group's leaders responsible for the actions of street-level members.
In September 2008, two top members of the Sumiyoshi-kai underworld group agreed to pay Y97.5 million (£640,000) to the relatives of a man shot dead when three gunmen opened fire in a bar in Gunma Prefecture.
Three customers were killed when the gangsters tried to assassinate a rival gang boss - who survived the attempt on his life.
Police discovered an exam paper containing 12 questions on appropriate action in a given situation that a gangster might find himself involved in as they investigated the murder in Shiga Prefecture of a member of a gang affiliated with the 40,000-strong Yamaguchi-gumi, which is based in Kobe.
The questions covered activities that were banned - which included everything from phone fraud to theft of vehicles - as well as ordering that all activities be reported to senior members of the gang.
"When you think about it, this is an extremely sensible move," said Jake Adelstein, an author who has written about Japan's underworld groups. "The Yamaguchi-gumi is essentially a gigantic corporation and if you are running a company of this scale then the first thing you want to do is reduce your liabilities....