@@ -0,0 +1,1056 @@
+// http://codeforces.com/problemset/problem/152/A%0A%0Aimport java.util.Scanner;%0A%0Apublic class Solution %7B%0A%0A%09public static void main(String%5B%5D args) %7B%0A%09%09Scanner read = new Scanner(System.in);%0A%0A%09%09int n = read.nextInt();%0A%09%09int m = read.nextInt();%0A%09%09%0A%09%09read.nextLine();%0A%09%09%0A%09%09String%5B%5D marksOfStudents = new String%5Bn%5D;%0A%09%09for (int i = 0; i %3C n; ++i) %7B%0A%09%09%09marksOfStudents%5Bi%5D = read.nextLine();%0A%09%09%7D%0A%09%09%0A%09%09boolean%5B%5D isSuccessful = new boolean%5Bn%5D;%0A%09%09for (int subjectIndex = 0; subjectIndex %3C m; ++subjectIndex) %7B%0A%09%09%09char maxMark = '0';%0A%09%09%09for (int i = 0; i %3C n; ++i) %7B%0A%09%09%09%09if (marksOfStudents%5Bi%5D.charAt(subjectIndex) %3E maxMark) %7B%0A%09%09%09%09%09maxMark = marksOfStudents%5Bi%5D.charAt(subjectIndex);%0A%09%09%09%09%7D%0A%09%09%09%7D%0A%09%09%09for (int i = 0;i %3C n; ++i) %7B%0A%09%09%09%09if (marksOfStudents%5Bi%5D.charAt(subjectIndex) == maxMark) %7B%0A%09%09%09%09%09isSuccessful%5Bi%5D = true;%0A%09%09%09%09%7D%0A%09%09%09%7D%0A%09%09%7D%0A%09%09%0A%09%09int numberOfSuccessfulStudents = 0;%0A%09%09for (int i = 0; i %3C n; ++i) %7B%0A%09%09%09if (isSuccessful%5Bi%5D) %7B%0A%09%09%09%09numberOfSuccessfulStudents++;%0A%09%09%09%7D%0A%09%09%7D%0A%09%09%0A%09%09System.out.println(numberOfSuccessfulStudents);%0A%09%09%0A%09%09// Close scanner%0A%09%09read.close();%0A%09%7D%0A%7D%0A

Create Marks.java