Finding if conditions in .java file
问题 I tried to make method which will finding all if conditions in .java file (I assume that file contain only correct if instructions). It should count all "if", but not that which are sorrounded with comments or treaded as string. I tried to solve this problem with StringTokenizer, but I don't know how elided line after "//" sign and strings sorrounded with " ".Is it possible to realize this problem in this way, at all? public int getIfCount() { int counter = 0; String t = ""; try { FileReader