Duplicate calls and print statements removal