Compiler writing is easy? No. (I've built compilers for large subsets of C and Java, as well as my own languages)
Lord help you if you try to write a perfectly conforming compiler for C++ (has it ever been done?), and the U.S. legal system is at least an order of magnitude more complex than that.