If it compiles, then as far as the compiler is concerned, it's correctly written.
If it runs and it produces the expected results, it's correctly written.
If it compiles, then as far as the compiler is concerned, it's correctly written.
If it runs and it produces the expected results, it's correctly written.