criyle/codenet-compile-errors huggingface dataset:
Language: Java

import java.io.*;

public class Main{
 public static void main(String[] args){
  BufferedReader reader=new BufferedReader(new InputStreamReader(System.in));
  try{
   String phrase =reader.readLine();
   int[] alphabet =new int[26];
   if(pharase.length()<=1200){
   //Search the length of the phrase
   for(int i=0;i<phrase.length();i++){
    char word =phrase.charAt(i);   //sesrch each case
    int word_s=(int)word-(int)'a'; //For counting lowercase
    int word_C=(int)word-(int)'A'; //For counting capitalcase
    //If a case in the phrase is "j"st alphabet,add 1 to the counter of it
    for(int j=0;j<26;j++){
     if(word_s==j||word_C==j){
      alphabet[j]++;
     }
   }
   }
    //Output the result (use ASCII code)
    for(int k=0;k<26;k++){
     System.out.println(" "+(char)(97+k)+" : "+alphabet[k]);
    }
  }catch(IOException e){
   System.out.println(e);
  }
}
 }
}

Compiler output:
Main.java:26: error: 'catch' without 'try'
  }catch(IOException e){
   ^
Main.java:6: error: 'try' without 'catch', 'finally' or resource declarations
  try{
  ^
2 errors
Language: Java

import java.io.*;

public class Main{
 public static void main(String[] args){
  BufferedReader reader=new BufferedReader(new InputStreamReader(System.in));
  String phrase;
  try{
  do{
  phrase =reader.readLine();
   int[] alphabet =new int[26];
   //Search the length of the phrase
   for(int i=0;i<phrase.length();i++){
    char word =phrase.charAt(i);   //sesrch each case
    int word_s=(int)word-(int)'a'; //For counting lowercase
    int word_C=(int)word-(int)'A'; //For counting capitalcase
    //If a case in the phrase is "j"st alphabet,add 1 to the counter of it
    for(int j=0;j<26;j++){
     if(word_s==j||word_C==j){
      alphabet[j]++;
     }
   }
 }while(phrase!=null);
    //Output the result (use ASCII code)
    for(int k=0;k<26;k++){
     System.out.println((char)(97+k)+" : "+alphabet[k]);
    }
  }catch(IOException e){
   System.out.println(e);
  }
}
}

Compiler output:
Main.java:27: error: while expected
  }catch(IOException e){
   ^
Main.java:7: error: 'try' without 'catch', 'finally' or resource declarations
  try{
  ^
Main.java:31: error: reached end of file while parsing
}
 ^
3 errors
Language: Java

import java.io.*;
import java.util.Scanner;

public class Main{
 public static void main(String[] args){

  String phrase;
  Scanner sc=new Scanner(System.in);
  do{
  phrase =sc.next();
   int[] alphabet =new int[26];
   //Search the length of the phrase
   for(int i=0;i<phrase.length();i++){
    char word =phrase.charAt(i);   //sesrch each case
    int word_s=(int)word-(int)'a'; //For counting lowercase
    int word_C=(int)word-(int)'A'; //For counting capitalcase
    //If a case in the phrase is "j"st alphabet,add 1 to the counter of it
    for(int j=0;j<26;j++){
     if(word_s==j||word_C==j){
      alphabet[j]++;
     }
   }
 }
 }while(phrase!=null);
    //Output the result (use ASCII code)
    for(int k=0;k<26;k++){
     System.out.println((char)(97+k)+" : "+alphabet[k]);
    }
}
}

Compiler output:
Main.java:27: error: cannot find symbol
     System.out.println((char)(97+k)+" : "+alphabet[k]);
                                           ^
  symbol:   variable alphabet
  location: class Main
1 error
Language: Java

import java.io.*;
import java.util.Scanner;

public class Main{
 public static void main(String[] args){

  String phrase;
  Scanner sc=new Scanner(System.in);
  int[] alphabet =new int[26];
  do{
  String past=phrase;
  phrase =sc.nextLine();
   //Search the length of the phrase
   for(int i=0;i<phrase.length();i++){
    char word =phrase.charAt(i);   //sesrch each case
    int word_s=(int)word-(int)'a'; //For counting lowercase
    int word_C=(int)word-(int)'A'; //For counting capitalcase
    //If a case in the phrase is "j"st alphabet,add 1 to the counter of it
    for(int j=0;j<26;j++){
     if(word_s==j||word_C==j){
      alphabet[j]++;
     }
   }
 }
 }while(past!=phrase);
    //Output the result (use ASCII code)
    for(int k=0;k<26;k++){
     System.out.println((char)(97+k) + " : " + alphabet[k]);
    }
}
}

Compiler output:
Main.java:25: error: cannot find symbol
 }while(past!=phrase);
        ^
  symbol:   variable past
  location: class Main
1 error
Language: Java

import java.io.*;
import java.util.Scanner;

public class Main{
 public static void main(String[] args){

  String phrase;
  Scanner sc=new Scanner(System.in);
  String past;
  int[] alphabet =new int[26];
  do{
  past=phrase;
  phrase =sc.nextLine();
   //Search the length of the phrase
   for(int i=0;i<phrase.length();i++){
    char word =phrase.charAt(i);   //sesrch each case
    int word_s=(int)word-(int)'a'; //For counting lowercase
    int word_C=(int)word-(int)'A'; //For counting capitalcase
    //If a case in the phrase is "j"st alphabet,add 1 to the counter of it
    for(int j=0;j<26;j++){
     if(word_s==j||word_C==j){
      alphabet[j]++;
     }
   }
 }
 }while(past!=phrase);
    //Output the result (use ASCII code)
    for(int k=0;k<26;k++){
     System.out.println((char)(97+k) + " : " + alphabet[k]);
    }
}
}

Compiler output:
Main.java:12: error: variable phrase might not have been initialized
  past=phrase;
       ^
1 error
Language: Java

import java.io.*;
import java.util.*;

public class aoj10020{
	public static void main(String[] args){
		Scanner scan = new Scanner(System.in);
		String sent;
		int[] alphaNum = new int[26];
		
		while(true){
			sent=scan.nextLine();
			if(sent.length()==0){
				break;
			}
			for(int i=0;i<sent.length();i++){
				char temp=sent.charAt(i);
				if(temp<97){
					temp+=32;
				}
				alphaNum[temp-97]+=1;
			}
		}
		for(int i=0;i<26;i++){
			char b=(char)(i+97);
			//String temp=new String((byte)b,"US-ASCII");
			System.out.println(b+" : "+alphaNum[i]);
		}
	}
}

Compiler output:
Main.java:4: error: class aoj10020 is public, should be declared in a file named aoj10020.java
public class aoj10020{
       ^
1 error
Language: Java

import java.io.*;
import java.util.*;

public class aoj10020{
	public static void main(String[] args){
		Scanner scan = new Scanner(System.in);
		String sent;
		int[] alphaNum = new int[26];
		
		//while(true){
			sent=scan.nextLine();
			//if(sent.length()==0){
			//	break;
			//}
			for(int i=0;i<sent.length();i++){
				char temp=sent.charAt(i);
				if(temp<97){
					temp+=32;
				}
				if(96<temp && temp<123){
					alphaNum[temp-97]+=1;
				}
			}
		//}
		for(int i=0;i<26;i++){
			char b=(char)(i+97);
			System.out.println(b+" : "+alphaNum[i]);
		}
	}
}

Compiler output:
Main.java:4: error: class aoj10020 is public, should be declared in a file named aoj10020.java
public class aoj10020{
       ^
1 error
Language: Java

import java.io.*;
import java.util.*;

public class Main{
	public static void main(String[] args){
		Scanner scan = new Scanner(System.in);
		String sent;
		int[] alphaNum = new int[26];
		
		while(scan.hasnext()){
			sent=scan.nextLine();
			if(sent.length()==0){
				break;
			}
			for(int i=0;i<sent.length();i++){
				char temp=sent.charAt(i);
				if(temp<97){
					temp+=32;
				}
				if(96<temp && temp<123){
					alphaNum[temp-97]+=1;
				}
			}
		}
		for(int i=0;i<26;i++){
			char b=(char)(i+97);
			System.out.println(b+" : "+alphaNum[i]);
		}
	}
}

Compiler output:
Main.java:10: error: cannot find symbol
		while(scan.hasnext()){
		          ^
  symbol:   method hasnext()
  location: variable scan of type Scanner
1 error
Language: Java

import java.util.Scanner;

public class Cc {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int[] count = new int[256];
		for (int i = 0; i < 256; i++) {
			count[i] = 0;
		}
		while (sc.hasNext()) {
			String x = sc.nextLine();
			for (int i = 0; i < x.length(); i++) {
				char ch = x.toLowerCase().charAt(i);
				int value = ch;
				count[value]++;
			}
		}
		for (char c = 'a'; c <= 'z'; c++) {
			System.out.println(c + " : " + count[c]);
		}
	}
}

Compiler output:
Main.java:3: error: class Cc is public, should be declared in a file named Cc.java
public class Cc {
       ^
1 error
Language: Java

import java.io.BufferedReader;
import java.io.InputStreamReader;

public class Main {
	public static void main(String[] arg) {
		BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
		try{
			int count;
			String line = reader.readLine();
			line=line.toLowerCase();
			for (char c = 'a'; c <= 'z'; c++) {
				count = 0;
				for (int i = 0; i < line.length(); i++) {
					if (line.charAt(i) == c) {
						count++;
					}
				}
				System.out.println(c + " : " + count);
			}
		}Finally
	}
}

Compiler output:
Main.java:7: error: 'try' without 'catch', 'finally' or resource declarations
		try{
		^
Main.java:20: error: not a statement
		}Finally
		 ^
Main.java:20: error: ';' expected
		}Finally
		        ^
3 errors
Language: Java

import java.util.Scanner;

public class Main {
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    int chars = new int[256];
    while (hasNextLine()) {
      String line = sc.nextLine();
      for (int i = 0; i < line.length(); i++) {
        char ch = Character.toLowerCase(line.charAt(i));
        chars[ch]++;
      }
    }
    for (char ch = 'a'; ch <= 'z'; ch++) {
      System.out.println(ch + ":" + char[ch]);
    }
  }
}

Compiler output:
Main.java:15: error: ']' expected
      System.out.println(ch + ":" + char[ch]);
                                         ^
Main.java:15: error: ';' expected
      System.out.println(ch + ":" + char[ch]);
                                           ^
2 errors
Language: Java

import java.util.Scanner;

public class Main {
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    int chars = new int[256];
    while (hasNextLine()) {
      String line = sc.nextLine();
      for (int i = 0; i < line.length(); i++) {
        char ch = Character.toLowerCase(line.charAt(i));
        chars[ch]++;
      }
    }
    for (char ch = 'a'; ch <= 'z'; ch++) {
      System.out.println(ch + ":" + chars[ch]);
    }
  }
}

Compiler output:
Main.java:6: error: incompatible types: int[] cannot be converted to int
    int chars = new int[256];
                ^
Main.java:7: error: cannot find symbol
    while (hasNextLine()) {
           ^
  symbol:   method hasNextLine()
  location: class Main
Main.java:11: error: array required, but int found
        chars[ch]++;
             ^
Main.java:15: error: array required, but int found
      System.out.println(ch + ":" + chars[ch]);
                                         ^
4 errors
Language: Java

import java.util.Scanner;

public class Main {
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    int chars = new int[256];
    while (hasNextLine()) {
      String line = sc.nextLine();
      for (int i = 0; i < line.length(); i++) {
        char ch = Character.toLowerCase(line.charAt(i));
        for (char j = 'a'; j <= 'z'; j++) {
          if (ch == j) {
            chars[j]++;
          }
        }
      }
    }
    for (char ch = 'a'; ch <= 'z'; ch++) {
      System.out.println(ch + ":" + chars[ch]);
    }
  }
}

Compiler output:
Main.java:6: error: incompatible types: int[] cannot be converted to int
    int chars = new int[256];
                ^
Main.java:7: error: cannot find symbol
    while (hasNextLine()) {
           ^
  symbol:   method hasNextLine()
  location: class Main
Main.java:13: error: array required, but int found
            chars[j]++;
                 ^
Main.java:19: error: array required, but int found
      System.out.println(ch + ":" + chars[ch]);
                                         ^
4 errors
Language: Java

import java.util.Scanner;

public class Main {
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    int[] chars = new int[256];
    while (hasNextLine()) {
      String line = sc.nextLine();
      for (int i = 0; i < line.length(); i++) {
        char ch = Character.toLowerCase(line.charAt(i));
        for (char j = 'a'; j <= 'z'; j++) {
          if (ch == j) {
            chars[j]++;
          }
        }
      }
    }
    for (char ch = 'a'; ch <= 'z'; ch++) {
      System.out.println(ch + ":" + chars[ch]);
    }
  }
}

Compiler output:
Main.java:7: error: cannot find symbol
    while (hasNextLine()) {
           ^
  symbol:   method hasNextLine()
  location: class Main
1 error
Language: Java

import java.util.Scanner;

public class test {
	public static void main(String[] arg) {
		Scanner sc = new Scanner(System.in);

		int count;
		String line = sc.nextLine();
		line = line.toLowerCase();

		for (char c = 'a'; c <= 'z'; c++) {
			count = 0;
			for (int i = 0; i < line.length(); i++) {
				if (line.charAt(i) == c) {
					count++;
				}
			}
			System.out.println(c + " : " + count);
		}
	}
}

Compiler output:
Main.java:3: error: class test is public, should be declared in a file named test.java
public class test {
       ^
1 error
Language: Java

import java.util.Scanner;

public class Main{
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
	 Scanner sc = new Scanner(System.in);
	      int[] chars = new int[256];
	           while (sc.hasNextLine()) {
	           String line = sc.nextLine();
	           for (int i = 0; i < line.length(); i++) {
	           char ch = Character.toLowerCase(line.charAt(i));
	           chars[ch] ++;
	                     }     
	 } 	
	for(char ch ='a'<='z';ch++){
		System.out.println(ch +":"+chars[ch]);
	}
}

	}

Compiler output:
Main.java:15: error: ';' expected
	for(char ch ='a'<='z';ch++){
	                          ^
1 error
Language: Java

import java.util.Scanner;

public class Main{
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
	 Scanner sc = new Scanner(System.in);
	      int[] chars = new int[256];
	           while (sc.hasNextLine()) {
	           String line = sc.nextLine();
	           for (int i = 0; i < line.length(); i++) {
	           char ch = Character.toLowerCase(line.charAt(i));
	           chars[ch] ++;
	                     }     
	 } 	
	for(char ch ='a'; ch<='z';ch++;){
		System.out.println(ch +" : "+chars[ch]);
	}
}

	}

Compiler output:
Main.java:15: error: ')' expected
	for(char ch ='a'; ch<='z';ch++;){
	                              ^
Main.java:15: error: illegal start of expression
	for(char ch ='a'; ch<='z';ch++;){
	                               ^
2 errors
Language: Java

import java.util.Scanner;

public class Main{
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
	 Scanner sc = new Scanner(System.in);
	      int[] chars = new int[256];
	           while (sc.hasNextLine()) {
	           String line = sc.nextLine();
	           for (int i = 0; i < line.length(); i++) {
	           char ch = Character.toLowerCase(line.charAt(i));
	           chars[ch] ++;
	                     }     
	 } 	
	for(char ch ='a'; ch<='z';ch++){
		System.out.println(ch +" : "+chars[ch]);
	}
}

	}

Compiler output:
Main.java:6: error: variable sc is already defined in method main(String[])
	 Scanner sc = new Scanner(System.in);
	         ^
1 error
Language: Java

import java.util.Scanner;
public class Main{
    public static void main(String[] args){
	Scanner sc=new Scanner(System.in);
	int[] chars=new int[256];
	for(int k=0;k<256;k++){
	    chars[k]=0;
	}
	while(sc.hasNextLine()){
	    String line=sc.nextLine();
	    for(int i=0;i<line.length();i++){
		char ch=Character.toLowerCase(line.charAt(i));
		chars[ch]++;
	    }
	}
	for(char ch='a';ch<='z';ch++){
	    System.out.println(ch+":"+ chars[ch]);
	}
    }
    printf("\n");
}

Compiler output:
Main.java:20: error: invalid method declaration; return type required
    printf("\n");
    ^
Main.java:20: error: illegal start of type
    printf("\n");
           ^
2 errors
Language: Java

import java.util.Scanner;
public class Main{
    public static void main(String[] args){
	Scanner sc=new Scanner(System.in);
	int[] chars=new int[256];
	for(int k=0;k<256;k++){
	    chars[k]=0;
	}
	while(sc.hasNextLine()){
	    String line=sc.nextLine();
	    for(int i=0;i<line.length();i++){
		char ch=Character.toLowerCase(line.charAt(i));
		chars[ch]++;
	    }
	}
	for(char ch='a';ch<='z';ch++){
	    System.out.println(ch+":"+ chars[ch]);
	}
    }
    System.out.printf("\n");
}

Compiler output:
Main.java:20: error: <identifier> expected
    System.out.printf("\n");
                     ^
Main.java:20: error: illegal start of type
    System.out.printf("\n");
                      ^
2 errors
Language: Java

import java.util.Scanner;
public class Main{
    public static void main(String[] args){
	Scanner sc=new Scanner(System.in);
	int[] chars=new int[256];
	for(int k=0;k<256;k++){
	    chars[k]=0;
	}
	while(sc.hasNextLine()){
	    String line=sc.nextLine();
	    for(int i=0;i<line.length();i++){
		char ch=Character.toLowerCase(line.charAt(i));
		chars[ch]++;
	    }
	}
	for(char ch='a';ch<='z';ch++){
	    System.out.println(ch +" : "+ chars[ch]);
	}
    }
    System.out.printf("\n");
}

Compiler output:
Main.java:20: error: <identifier> expected
    System.out.printf("\n");
                     ^
Main.java:20: error: illegal start of type
    System.out.printf("\n");
                      ^
2 errors
Language: Java

import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		while (sc.hasNextLine()) {
			String s = sc.nextLine();
			int[] chars = new int[256];
			for (int i = 0; i < s.length(); i++) {
				char ch = Character.toLowerCase(s.charAt(i));
				chars[ch]++;
			}
		}
		for (char ch = 97; ch <= 122; ch++) {
			System.out.println(ch + " : " + chars[ch]);
		}
	}
}

Compiler output:
Main.java:15: error: cannot find symbol
			System.out.println(ch + " : " + chars[ch]);
			                                ^
  symbol:   variable chars
  location: class Main
1 error
Language: Java

mport java.util.Scanner; 
 
public class Main {   
	public static void main(String[] args) {     
   Scanner sc = new Scanner(System.in);  
   int[] chars = new int[256];    
 while (sc.hasNextLine()) {   
    String line = sc.nextLine();  
     for (int i = 0; i < line.length(); i++) {       
  char ch = Character.toLowerCase(line.charAt(i)); 
  chars[ch]++;   
      }
     }     
for (char ch = 'a'; ch <= 'z'; ch++) {       
	System.out.println(ch + " : " + chars[ch]);     
}   
}
 } 

Compiler output:
Main.java:1: error: class, interface, enum, or record expected
mport java.util.Scanner; 
^
1 error
Language: Java

mport java.util.Scanner; 
 
public class Main{   
	public static void main(String[] args) {     
   Scanner sc = new Scanner(System.in);  
   int[] chars = new int[256];    
 while (sc.hasNextLine()) {   
    String line = sc.nextLine();  
     for (int i = 0; i < line.length(); i++) {       
  char ch = Character.toLowerCase(line.charAt(i)); 
  chars[ch]++;   
      }
     }     
for (char ch = 'a'; ch <= 'z'; ch++) {       
	System.out.println(ch + " : " + chars[ch]);     
}   
}
 } 

Compiler output:
Main.java:1: error: class, interface, enum, or record expected
mport java.util.Scanner; 
^
1 error
Language: Java

import java.util.Scanner;

public class CountingCharacters {
	public static void main(String args[]) {
		Scanner scan = new Scanner(System.in);
		String str = scan.nextLine();
		int[] a = new int[30];
		for (int j = 0; j < 30; j++) {
			a[j] = 0;
		}
		for (int i = 0; i < str.length(); i++) {
			String str2 = String.valueOf(str.charAt(i));
			String str3 = str2.toLowerCase();
			switch (str3) {
			case "a":
				a[0] += 1;
				break;
			case "b":
				a[1] += 1;
				break;
			case "c":
				a[2] += 1;
				break;
			case "d":
				a[3] += 1;
				break;
			case "e":
				a[4] += 1;
				break;
			case "f":
				a[5] += 1;
				break;
			case "g":
				a[6] += 1;
				break;
			case "h":
				a[7] += 1;
				break;
			case "i":
				a[8] += 1;
				break;
			case "j":
				a[9] += 1;
				break;
			case "k":
				a[10] += 1;
				break;
			case "l":
				a[11] += 1;
				break;
			case "m":
				a[12] += 1;
				break;
			case "n":
				a[13] += 1;
				break;
			case "o":
				a[14] += 1;
				break;
			case "p":
				a[15] += 1;
				break;
			case "q":
				a[16] += 1;
				break;
			case "r":
				a[17] += 1;
				break;
			case "s":
				a[18] += 1;
				break;
			case "t":
				a[19] += 1;
				break;
			case "u":
				a[20] += 1;
				break;
			case "v":
				a[21] += 1;
				break;
			case "w":
				a[22] += 1;
				break;
			case "x":
				a[23] += 1;
				break;
			case "y":
				a[24] += 1;
				break;
			case "z":
				a[25] += 1;
				break;
			}
		}
		System.out.println("a : " + a[0]);
		System.out.println("b : " + a[1]);
		System.out.println("c : " + a[2]);
		System.out.println("d : " + a[3]);
		System.out.println("e : " + a[4]);
		System.out.println("f : " + a[5]);
		System.out.println("g : " + a[6]);
		System.out.println("h : " + a[7]);
		System.out.println("i : " + a[8]);
		System.out.println("j : " + a[9]);
		System.out.println("k : " + a[10]);
		System.out.println("l : " + a[11]);
		System.out.println("m : " + a[12]);
		System.out.println("n : " + a[13]);
		System.out.println("o : " + a[14]);
		System.out.println("p : " + a[15]);
		System.out.println("q : " + a[16]);
		System.out.println("r : " + a[17]);
		System.out.println("s : " + a[18]);
		System.out.println("t : " + a[19]);
		System.out.println("u : " + a[20]);
		System.out.println("v : " + a[21]);
		System.out.println("w : " + a[22]);
		System.out.println("x : " + a[23]);
		System.out.println("y : " + a[24]);
		System.out.println("z : " + a[25]);
		System.out.println();
	}
}

Compiler output:
Main.java:3: error: class CountingCharacters is public, should be declared in a file named CountingCharacters.java
public class CountingCharacters {
       ^
1 error
Language: Java

import java.util.Scanner;

public class Main {
	public static void main(String args[]) {
		Scanner scan = new Scanner(System.in);
		String str = scan.nextLine();
		int[] a = new int[30];
		for (int j = 0; j < 30; j++) {
			a[j] = 0;
		}
		while (Scanner.hasNext() == false) {
			for (int i = 0; i < str.length(); i++) {
				String str2 = String.valueOf(str.charAt(i));
				String str3 = str2.toLowerCase();
				switch (str3) {
				case "a":
					a[0] += 1;
					break;
				case "b":
					a[1] += 1;
					break;
				case "c":
					a[2] += 1;
					break;
				case "d":
					a[3] += 1;
					break;
				case "e":
					a[4] += 1;
					break;
				case "f":
					a[5] += 1;
					break;
				case "g":
					a[6] += 1;
					break;
				case "h":
					a[7] += 1;
					break;
				case "i":
					a[8] += 1;
					break;
				case "j":
					a[9] += 1;
					break;
				case "k":
					a[10] += 1;
					break;
				case "l":
					a[11] += 1;
					break;
				case "m":
					a[12] += 1;
					break;
				case "n":
					a[13] += 1;
					break;
				case "o":
					a[14] += 1;
					break;
				case "p":
					a[15] += 1;
					break;
				case "q":
					a[16] += 1;
					break;
				case "r":
					a[17] += 1;
					break;
				case "s":
					a[18] += 1;
					break;
				case "t":
					a[19] += 1;
					break;
				case "u":
					a[20] += 1;
					break;
				case "v":
					a[21] += 1;
					break;
				case "w":
					a[22] += 1;
					break;
				case "x":
					a[23] += 1;
					break;
				case "y":
					a[24] += 1;
					break;
				case "z":
					a[25] += 1;
					break;
				}
			}
		}
		System.out.println("a : " + a[0]);
		System.out.println("b : " + a[1]);
		System.out.println("c : " + a[2]);
		System.out.println("d : " + a[3]);
		System.out.println("e : " + a[4]);
		System.out.println("f : " + a[5]);
		System.out.println("g : " + a[6]);
		System.out.println("h : " + a[7]);
		System.out.println("i : " + a[8]);
		System.out.println("j : " + a[9]);
		System.out.println("k : " + a[10]);
		System.out.println("l : " + a[11]);
		System.out.println("m : " + a[12]);
		System.out.println("n : " + a[13]);
		System.out.println("o : " + a[14]);
		System.out.println("p : " + a[15]);
		System.out.println("q : " + a[16]);
		System.out.println("r : " + a[17]);
		System.out.println("s : " + a[18]);
		System.out.println("t : " + a[19]);
		System.out.println("u : " + a[20]);
		System.out.println("v : " + a[21]);
		System.out.println("w : " + a[22]);
		System.out.println("x : " + a[23]);
		System.out.println("y : " + a[24]);
		System.out.println("z : " + a[25]);
	}
}

Compiler output:
Main.java:11: error: non-static method hasNext() cannot be referenced from a static context
		while (Scanner.hasNext() == false) {
		              ^
1 error
Language: Java

import java.util.Scanner;

public class Mian {
	public static void main(String args[]) {
		Scanner scan = new Scanner(System.in);
		String str = scan.nextLine();
		int[] a = new int[30];
		for (int j = 0; j < 30; j++) {
			a[j] = 0;
		}
		while (scan.hasNextLine()) {
			for (int i = 0; i < str.length(); i++) {
				String str2 = String.valueOf(str.charAt(i));
				String str3 = str2.toLowerCase();
				switch (str3) {
				case "a":
					a[0] += 1;
					break;
				case "b":
					a[1] += 1;
					break;
				case "c":
					a[2] += 1;
					break;
				case "d":
					a[3] += 1;
					break;
				case "e":
					a[4] += 1;
					break;
				case "f":
					a[5] += 1;
					break;
				case "g":
					a[6] += 1;
					break;
				case "h":
					a[7] += 1;
					break;
				case "i":
					a[8] += 1;
					break;
				case "j":
					a[9] += 1;
					break;
				case "k":
					a[10] += 1;
					break;
				case "l":
					a[11] += 1;
					break;
				case "m":
					a[12] += 1;
					break;
				case "n":
					a[13] += 1;
					break;
				case "o":
					a[14] += 1;
					break;
				case "p":
					a[15] += 1;
					break;
				case "q":
					a[16] += 1;
					break;
				case "r":
					a[17] += 1;
					break;
				case "s":
					a[18] += 1;
					break;
				case "t":
					a[19] += 1;
					break;
				case "u":
					a[20] += 1;
					break;
				case "v":
					a[21] += 1;
					break;
				case "w":
					a[22] += 1;
					break;
				case "x":
					a[23] += 1;
					break;
				case "y":
					a[24] += 1;
					break;
				case "z":
					a[25] += 1;
					break;
				}
			}
			str = scan.nextLine();
		}
		System.out.println("a : " + a[0]);
		System.out.println("b : " + a[1]);
		System.out.println("c : " + a[2]);
		System.out.println("d : " + a[3]);
		System.out.println("e : " + a[4]);
		System.out.println("f : " + a[5]);
		System.out.println("g : " + a[6]);
		System.out.println("h : " + a[7]);
		System.out.println("i : " + a[8]);
		System.out.println("j : " + a[9]);
		System.out.println("k : " + a[10]);
		System.out.println("l : " + a[11]);
		System.out.println("m : " + a[12]);
		System.out.println("n : " + a[13]);
		System.out.println("o : " + a[14]);
		System.out.println("p : " + a[15]);
		System.out.println("q : " + a[16]);
		System.out.println("r : " + a[17]);
		System.out.println("s : " + a[18]);
		System.out.println("t : " + a[19]);
		System.out.println("u : " + a[20]);
		System.out.println("v : " + a[21]);
		System.out.println("w : " + a[22]);
		System.out.println("x : " + a[23]);
		System.out.println("y : " + a[24]);
		System.out.println("z : " + a[25]);
	}
}

Compiler output:
Main.java:3: error: class Mian is public, should be declared in a file named Mian.java
public class Mian {
       ^
1 error
Language: Java

import java.util.Scanner;
public class week4_2 {
	 public static void main(String[] args) {
		 Scanner sc = new Scanner(System.in);
		 int[] chars = new int[256];
		 while (sc.hasNextLine()) {
			 String line = sc.nextLine();
			 for (int i = 0; i < line.length(); i++) {
				 char ch = Character.toLowerCase(line.charAt(i));
				 if(ch>='a' && ch<='z'){
					 chars[ch]=chars[ch]+1;
				 }
				 }
			 }
		 	for (char ch = 'a'; ch <= 'z'; ch++) {
			 System.out.println(ch + " : " + chars[ch]);
			 } 
		 }
	 }

Compiler output:
Main.java:2: error: class week4_2 is public, should be declared in a file named week4_2.java
public class week4_2 {
       ^
1 error
Language: Java

public class Main {
	public static void main(String[] args) {
		int[] note = new int['z'+1];
		Scanner sc = new Scanner(System.in);
		String str = sc.nextLine();
		str = str.toLowerCase();
		for ( int i = 0; i < str.length(); i++ )
			note[str.charAt(i)]++;
		for ( int i = 'a'; i <= 'z'; i++ )
			System.out.println((char)i+" : "+note[i]);
	}
}

Compiler output:
Main.java:4: error: cannot find symbol
		Scanner sc = new Scanner(System.in);
		^
  symbol:   class Scanner
  location: class Main
Main.java:4: error: cannot find symbol
		Scanner sc = new Scanner(System.in);
		                 ^
  symbol:   class Scanner
  location: class Main
2 errors
Language: Java

import java.util.*;

class Main{
    public static void main(String[] args){
	Scanner s = new Scanner(System.in);

	while(s.hasNext()){
	    String str = s.nextLine();
	}
	int[] alpha = new int[26];
	for(int i = 0 ; i < 26 ; i++) alpha[i] = 0;
	String st = str.toLowerCase();
	//System.out.println("OK");
	for(int i = 0 ; i < str.length() ; i++){
	    char c = st.charAt(i);
	    if('a' <= c && c <= 'z') alpha[c - 'a']++;
	    else continue;
	}
	
	for(int i = 0 ; i < 26 ; i++){
	    System.out.println((char)('a' + i) + " : " + alpha[i]);
	}	
    }
}

Compiler output:
Main.java:12: error: cannot find symbol
	String st = str.toLowerCase();
	            ^
  symbol:   variable str
  location: class Main
Main.java:14: error: cannot find symbol
	for(int i = 0 ; i < str.length() ; i++){
	                    ^
  symbol:   variable str
  location: class Main
2 errors
Language: Java

import java.util.Scanner;
class Main{
  public static void main(String[] args){
    Scanner sc = new Scanner(System.in);
    int counter[] = new int[26]
    while(sc.hasNext()) {
      String str = sc.next();
      for (int i = 0; i < str.length(); i++) {
        int n = str.charAt(i) - 'a';
        counter[n]++
      }
    }
    for (i = 0; i < 26; i++) {
      char ch = i+'a'
      System.out.println(ch + " : " + counter[i]);
    }
  }
}

Compiler output:
Main.java:5: error: ';' expected
    int counter[] = new int[26]
                               ^
Main.java:10: error: ';' expected
        counter[n]++
                    ^
Main.java:14: error: ';' expected
      char ch = i+'a'
                     ^
3 errors
Language: Java

import java.util.Scanner;
class Main{
  public static void main(String[] args){
    Scanner sc = new Scanner(System.in);
    int counter[] = new int[26];
    while(sc.hasNext()) {
      String str = sc.next();
      for (int i = 0; i < str.length(); i++) {
        int n = str.charAt(i) - 'a';
        counter[n]++;
      }
    }
    for (i = 0; i < 26; i++) {
      char ch = i+'a';
      System.out.println(ch + " : " + counter[i]);
    }
  }
}

Compiler output:
Main.java:13: error: cannot find symbol
    for (i = 0; i < 26; i++) {
         ^
  symbol:   variable i
  location: class Main
Main.java:13: error: cannot find symbol
    for (i = 0; i < 26; i++) {
                ^
  symbol:   variable i
  location: class Main
Main.java:13: error: cannot find symbol
    for (i = 0; i < 26; i++) {
                        ^
  symbol:   variable i
  location: class Main
Main.java:14: error: cannot find symbol
      char ch = i+'a';
                ^
  symbol:   variable i
  location: class Main
Main.java:15: error: cannot find symbol
      System.out.println(ch + " : " + counter[i]);
                                              ^
  symbol:   variable i
  location: class Main
5 errors
Language: Java

import java.util.Scanner;
class Main{
  public static void main(String[] args){
    Scanner sc = new Scanner(System.in);
    int counter[] = new int[26];
    while(sc.hasNext()) {
      String str = sc.next();
      for (int i = 0; i < str.length(); i++) {
        int n = str.charAt(i) - 'a';
        counter[n]++;
      }
    }
    for (int i = 0; i < 26; i++) {
      char ch = i+'a';
      System.out.println(ch + " : " + counter[i]);
    }
  }
}

Compiler output:
Main.java:14: error: incompatible types: possible lossy conversion from int to char
      char ch = i+'a';
                 ^
1 error
Language: Java

import java.util.Scanner;
class Main{
  public static void main(String[] args){
    Scanner sc = new Scanner(System.in);
    int counter[] = new int[26];
    while(sc.hasNext()) {
      String str = sc.next();
      for (int i = 0; i < str.length(); i++) {
        int n = str.charAt(i) - 'a';
        counter[n]++;
      }
    }
    for (int i = 0; i < 26; i++) {
      n = i + 'a'
      char ch = (char)n;
      System.out.println(ch + " : " + counter[i]);
    }
  }
}

Compiler output:
Main.java:14: error: ';' expected
      n = i + 'a'
                 ^
1 error
Language: Java

import java.util.Scanner;
class Main{
  public static void main(String[] args){
    Scanner sc = new Scanner(System.in);
    int counter[] = new int[26];
    while(sc.hasNext()) {
      String str = sc.next();
      for (int i = 0; i < str.length(); i++) {
        int n = str.charAt(i) - 'a';
        counter[n]++;
      }
    }
    for (int i = 0; i < 26; i++) {
      n = i + 'a';
      char ch = (char)n;
      System.out.println(ch + " : " + counter[i]);
    }
  }
}

Compiler output:
Main.java:14: error: cannot find symbol
      n = i + 'a';
      ^
  symbol:   variable n
  location: class Main
Main.java:15: error: cannot find symbol
      char ch = (char)n;
                      ^
  symbol:   variable n
  location: class Main
2 errors
Language: Java

import java.util.*;
public class Main{
public static void main(String[] args){
        Scanner s=new Scanner(System.in);
        int c[]=new int[26];
        for(int i=0;i<26;i++)c[i]=0; 
        while(s.hasNext()){
            String str=s.nextLine();
            for(int i=0;i<str.length();i++){
                char temp=Character.toLowerCase(str.charAt(i));
                if(!('a'<= temp&&temp<='z'))continue;
                c[temp-'a']++;
            }
        }
        for(int i=0;i<26;i++)System.out.println((char)('a'+i)+" : "+c[i]);
    }
}
}

Compiler output:
Main.java:18: error: class, interface, enum, or record expected
}
^
1 error
Language: Java

import java.util.*;
public class Main{
    static Scanner kbd = new Scanner(System.in);
    public  static void main(String[] args){
	String c;
	String[] alps = {"a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k",
			 "l", "m", "n", "o", "p", "q", "r", "s", "t", "u", "v",
			 "w", "x", "y", "z"};
	String[] alpb = {"A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K",
			 "L", "M", "N", "O", "P", "Q", "R", "S", "T", "U", "V",
			 "W", "X", "Y", "Z"};
	int[] cnt = new int[26];
	while(kbd.hasNext()){
	    String s = kbd.nextLine();
	    int i;
	    for(i=0; i<s.length(); i++){
		c = s.substring(i, i+1);
		int j=0;
		while(j<26 && !alps[j].equals(c)) j++;
		if(j<26) cnt[j]++; 
		j=0;
		while(j<26 && !c.equals(alpb[j])) j++;
		if(j<26) cnt[j]++;
	    }
	}
	for(i=0; i<cnt.length; i++){
	    System.out.println(alps[i]+" : "+cnt[i]);
	}
    }
}

Compiler output:
Main.java:26: error: cannot find symbol
	for(i=0; i<cnt.length; i++){
	    ^
  symbol:   variable i
  location: class Main
Main.java:26: error: cannot find symbol
	for(i=0; i<cnt.length; i++){
	         ^
  symbol:   variable i
  location: class Main
Main.java:26: error: cannot find symbol
	for(i=0; i<cnt.length; i++){
	                       ^
  symbol:   variable i
  location: class Main
Main.java:27: error: cannot find symbol
	    System.out.println(alps[i]+" : "+cnt[i]);
	                            ^
  symbol:   variable i
  location: class Main
Main.java:27: error: cannot find symbol
	    System.out.println(alps[i]+" : "+cnt[i]);
	                                         ^
  symbol:   variable i
  location: class Main
5 errors
Language: Java

import java.util.*;
import java.lang.Character;

public class aoj10020{
  public static void Main(String[] args){
    Scanner sc = new Scanner(System.in);
    int[] a = new int[26];
    while(sc.hasNext()){
    	String s = sc.nextLine();
    	for(int i=0;i<s.length();++i){
    		char c = s.charAt(i);
    		c = Character.toLowerCase(c);
    		if('a'<=c && c<='z')++a[c-'a'];
    	}
    }
	for(int i=0;i<26;++i)
		System.out.printf("%c : %d\n", i+'a', a[i]);
  }
}

Compiler output:
Main.java:4: error: class aoj10020 is public, should be declared in a file named aoj10020.java
public class aoj10020{
       ^
1 error
Language: Java

import java.io.*;
import java.util.Scanner;

class Main {
    public static void main (String[] args) throws IOException {
        InputStreamReader isr = new InputStreamReader(System.in);
        BufferedReader br = new BufferedReader(isr);
        int[] cs = new int[26];
        for (;;) {
        String line = br.readLine();
if (line == null || line.length == 0) {
break;
}
        for (int ii = 0; ii < line.length(); ii++) {
            char c = line.charAt(ii);
            if (Character.isUpperCase(c)) {
                c = Character.toLowerCase(c);
            }
            if (!Character.isLowerCase(c)) {
                continue;
            }
            cs[(int)c - (int)'a']++;
        }
        }
        }
        for (int ii = 0, c = (int)'a'; ii < cs.length; ii++, c++) {
            System.out.println((char)c + " : " + cs[ii]);
        }
    }
}

Compiler output:
Main.java:26: error: illegal start of type
        for (int ii = 0, c = (int)'a'; ii < cs.length; ii++, c++) {
        ^
Main.java:26: error: > or ',' expected
        for (int ii = 0, c = (int)'a'; ii < cs.length; ii++, c++) {
                                                     ^
Main.java:26: error: <identifier> expected
        for (int ii = 0, c = (int)'a'; ii < cs.length; ii++, c++) {
                                                         ^
Main.java:26: error: <identifier> expected
        for (int ii = 0, c = (int)'a'; ii < cs.length; ii++, c++) {
                                                              ^
Main.java:30: error: class, interface, enum, or record expected
}
^
5 errors
Language: Java

class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int[] alpha = { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
				0, 0, 0, 0, 0, 0, 0, 0 };
		char[] bet = { 'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k',
				'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w',
				'x', 'y', 'z' };
		int kaisuu;
		while (sc.hasNext()) {
			String s = sc.next();
			for (kaisuu = 0; kaisuu < s.length(); kaisuu++) {
				char moji = s.charAt(kaisuu);
				if (moji >= 'A' & moji <= 'Z') {
					alpha[moji - 'A'] += 1;
				} else if (moji >= 'a' & moji <= 'z') {
					alpha[moji - 'a'] += 1;
				}
			}
		}
		for (kaisuu = 0; kaisuu < 26; kaisuu++) {
			System.out.println(bet[kaisuu] + " : " + alpha[kaisuu]);
		}
	}
}

Compiler output:
Main.java:3: error: cannot find symbol
		Scanner sc = new Scanner(System.in);
		^
  symbol:   class Scanner
  location: class Main
Main.java:3: error: cannot find symbol
		Scanner sc = new Scanner(System.in);
		                 ^
  symbol:   class Scanner
  location: class Main
2 errors
Language: C

#include <stdio.h>
#include <ctype.h>

int main(void)
{
	char ch;
	int	i, num;
	int	count[26] = {0};

	while(1){
		scanf("%c", &ch);

		if(isalpha(ch) != 0){

			if(isupper(ch) == 0){

				for(i = 0;i <= ch - 'a';i++){
					if(ch - 'a' == i){
						count[i]++;
					}
				}

			} else {

				for(i = 0;i <= ch - 'A';i++){
					if(ch - 'A' == i){
						count[i]++;
					}
				}

			}

		} 

		if(ch == '\n') break;
	}

	for(i = 0;i < 26;i++){
		printf("%c : %d\n", 'a' + i, count[i]);
	}

	return 0;

Compiler output:
main.c: In function 'main':
main.c:42:9: error: expected declaration or statement at end of input
   42 |         return 0;
      |         ^~~~~~
Language: C

#include <stdio.h>

int main(void)
{

	int sum[26];
	int i;
	char s[1201];

	for(i=0;i<26;i++)
		s[i] = 0;

	gets("%s",s);

	i=0;

	while(s[i] == '\0'){
		sum[s[i]-'a']++; 
		i++;
	}

	for(i=0;i<26;i++)
		printf("%c : %d\n",'a'+i,s[i]);


	return 0;
}

	

Compiler output:
main.c: In function 'main':
main.c:13:9: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
   13 |         gets("%s",s);
      |         ^~~~
      |         fgets
Language: C

#include <stdio.h>

int main(void)
{

	int sum[26];
	int i;
	char s[1201];

	for(i=0;i<26;i++)
		sum[i] = 0;

	gets("%s",s);

	i=0;

	while(s[i] == '\0'){
		sum[s[i]-'a']++; 
		i++;
	}

	for(i=0;i<26;i++)
		printf("%c : %d\n",'a'+i,s[i]);


	return 0;
}

	

Compiler output:
main.c: In function 'main':
main.c:13:9: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
   13 |         gets("%s",s);
      |         ^~~~
      |         fgets
Language: C

#include <stdio.h>
#include<cctype>

int main(void)
{

	int sum[26];
	int i;
	char s;

	for(i=0;i<26;i++)
		sum[i] = 0;



	while(scanf("%c",&s) != EOF){
		if(0 <=tolower(s)-'a' && tolower(s)-'a'<=25)
			sum[tolower(s)-'a']++; 
		
	}

	for(i=0;i<26;i++)
		printf("%c : %d\n",'a'+i,sum[i]);


	return 0;
}

	

Compiler output:
main.c:2:9: fatal error: cctype: No such file or directory
    2 | #include<cctype>
      |         ^~~~~~~~
compilation terminated.
Language: C

#include<stdio.h>
int main(){

char c;
int i,n[26];

while((scanf("%c",&c))!=EOF){
if(c>='a'&&c<='z'){
n[c-97]++;
}else if(c>='A'&&c<='Z'){
n[c-65]++;
}
if(c=='\n')break;
}

for(i=0;i<26;i++){
printf(""%c:%d\n",'a'+i,n[i]);
}

return 0;
}

Compiler output:
main.c: In function 'main':
main.c:17:10: error: invalid operands to binary % (have 'char *' and 'int')
   17 | printf(""%c:%d\n",'a'+i,n[i]);
      |        ~~^
      |        |
      |        char *
main.c:17:12: error: expected ')' before ':' token
   17 | printf(""%c:%d\n",'a'+i,n[i]);
      |       ~    ^
      |            )
main.c:17:15: error: stray '\' in program
   17 | printf(""%c:%d\n",'a'+i,n[i]);
      |               ^
main.c:17:17: warning: missing terminating " character
   17 | printf(""%c:%d\n",'a'+i,n[i]);
      |                 ^
main.c:17:17: error: missing terminating " character
   17 | printf(""%c:%d\n",'a'+i,n[i]);
      |                 ^~~~~~~~~~~~~~
main.c:17:17: error: expected ';' before '}' token
   17 | printf(""%c:%d\n",'a'+i,n[i]);
      |                 ^
      |                 ;
   18 | }
      | ~
Language: C

#include<stdio.h>
int main(){
  int a=0,b=0,len,s[26]={0};
  char c,e[1200];
  scanf("%s",e);
  len=strlen(e);
  while(1){
    a++;
    c='a';
    while(1){
      if(e[a]==c){
	s[b]++;
      }
      b++;
      c++;
      else if(c>'z')break;
    }
    if(a>1200)break;
  }

    c='a';
    a=0;
    while(1){
      printf("%c : %d\n",c,s[a]);
      a++;
      c++;
      if(a>25)break;
    }
    return 0;
}

Compiler output:
main.c: In function 'main':
main.c:6:7: error: implicit declaration of function 'strlen' [-Wimplicit-function-declaration]
    6 |   len=strlen(e);
      |       ^~~~~~
main.c:2:1: note: include '<string.h>' or provide a declaration of 'strlen'
    1 | #include<stdio.h>
  +++ |+#include <string.h>
    2 | int main(){
main.c:6:7: warning: incompatible implicit declaration of built-in function 'strlen' [-Wbuiltin-declaration-mismatch]
    6 |   len=strlen(e);
      |       ^~~~~~
main.c:6:7: note: include '<string.h>' or provide a declaration of 'strlen'
main.c:16:7: error: 'else' without a previous 'if'
   16 |       else if(c>'z')break;
      |       ^~~~
Language: C

#include<stdio.h>
int main(){
  int a=0,b=0,len,s[26]={0};
  char c,e[1200];
  scanf("%s",e);
  len=strlen(e);
  while(1){
    a++;
    c='a';
    while(1){
      if(e[a]==c){
	s[b]++;
      }
      b++;
      c++;
      else if(c>'z')break;
    }
    if(a>1200)break;
  }
  
  c='a';
  a=0;
  while(1){
    printf("%c : %d\n",c,s[a]);
    a++;
    c++;
    if(a>25)break;
  }
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:6:7: error: implicit declaration of function 'strlen' [-Wimplicit-function-declaration]
    6 |   len=strlen(e);
      |       ^~~~~~
main.c:2:1: note: include '<string.h>' or provide a declaration of 'strlen'
    1 | #include<stdio.h>
  +++ |+#include <string.h>
    2 | int main(){
main.c:6:7: warning: incompatible implicit declaration of built-in function 'strlen' [-Wbuiltin-declaration-mismatch]
    6 |   len=strlen(e);
      |       ^~~~~~
main.c:6:7: note: include '<string.h>' or provide a declaration of 'strlen'
main.c:16:7: error: 'else' without a previous 'if'
   16 |       else if(c>'z')break;
      |       ^~~~
Language: C

#include<stdio.h>
int main(){
  char c;
  int a[26]={0};
  int i,j;
  whlie( scanf("%c",&c)!=EOF){
      if(c>='A' && c<='Z') c+='a'-'A';
      if(c>='a' && c<='z') a[c-'a']++;
  }
    
    for(i=0;i<26;i++){
      printf("%c : %d\n",'a'+i,a[i]);
    }
    return 0;
}
 

Compiler output:
main.c: In function 'main':
main.c:6:3: error: implicit declaration of function 'whlie' [-Wimplicit-function-declaration]
    6 |   whlie( scanf("%c",&c)!=EOF){
      |   ^~~~~
main.c:6:30: error: expected ';' before '{' token
    6 |   whlie( scanf("%c",&c)!=EOF){
      |                              ^
      |                              ;
Language: C

#include <stdio.h>
int main(){
int abc[26];
int ,x,i;
while((x=getchar())!=EOF){
 x=x-'a';
 abc[x]=abc[x]++;
}
for(i=0;i<26;i++){
printf("%s:%d\n",97+i,abc[i]);
}
return 0;
}

Compiler output:
main.c: In function 'main':
main.c:4:5: error: expected identifier or '(' before ',' token
    4 | int ,x,i;
      |     ^
main.c:5:8: error: 'x' undeclared (first use in this function)
    5 | while((x=getchar())!=EOF){
      |        ^
main.c:5:8: note: each undeclared identifier is reported only once for each function it appears in
main.c:9:5: error: 'i' undeclared (first use in this function)
    9 | for(i=0;i<26;i++){
      |     ^
Language: C

#include<stdio.h>
int main()
{
	char ch;
	int count[26]={0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0};
	int i;

	while ( scanf("%c", &ch) != EOF )
	{
    	switch(ch)

    		int num=ch-'a';
    		count[num]++;

	}

	for(i=0;i<26;i++){
      printf("%c : %d\n",'a'+i,count[i]);
    }

	return (0);
}

Compiler output:
main.c: In function 'main':
main.c:12:17: error: expected expression before 'int'
   12 |                 int num=ch-'a';
      |                 ^~~
main.c:13:23: error: 'num' undeclared (first use in this function)
   13 |                 count[num]++;
      |                       ^~~
main.c:13:23: note: each undeclared identifier is reported only once for each function it appears in
Language: C

int main(int argc, const char * argv[]) {
    // insert code here...
    int i,str[26];
    int s[26];
    char j;
    
    for(i = 0;i < 26;i++){
        s[i] = 0;
        str[i] = 'a' + i;
    }
    while(scanf("%s", &j) != EOF){
        for(i = 0;i < 26;i++){
            if(str[i] == j || str[i] == j + 0x20){
                s[i]++;
            }
        }
    }
    for(i = 0;i < 26;i++){
        printf("%c : %d\n", str[i], s[i]);
    }
    return (0);
}

Compiler output:
main.c: In function 'main':
main.c:11:11: error: implicit declaration of function 'scanf' [-Wimplicit-function-declaration]
   11 |     while(scanf("%s", &j) != EOF){
      |           ^~~~~
main.c:1:1: note: include '<stdio.h>' or provide a declaration of 'scanf'
  +++ |+#include <stdio.h>
    1 | int main(int argc, const char * argv[]) {
main.c:11:11: warning: incompatible implicit declaration of built-in function 'scanf' [-Wbuiltin-declaration-mismatch]
   11 |     while(scanf("%s", &j) != EOF){
      |           ^~~~~
main.c:11:11: note: include '<stdio.h>' or provide a declaration of 'scanf'
main.c:11:30: error: 'EOF' undeclared (first use in this function)
   11 |     while(scanf("%s", &j) != EOF){
      |                              ^~~
main.c:11:30: note: 'EOF' is defined in header '<stdio.h>'; this is probably fixable by adding '#include <stdio.h>'
main.c:11:30: note: each undeclared identifier is reported only once for each function it appears in
main.c:19:9: error: implicit declaration of function 'printf' [-Wimplicit-function-declaration]
   19 |         printf("%c : %d\n", str[i], s[i]);
      |         ^~~~~~
main.c:19:9: note: include '<stdio.h>' or provide a declaration of 'printf'
main.c:19:9: warning: incompatible implicit declaration of built-in function 'printf' [-Wbuiltin-declaration-mismatch]
main.c:19:9: note: include '<stdio.h>' or provide a declaration of 'printf'
Language: C

#include<stdio.h>
int main(void){
    char sen;
    int i,counter[26]={0},num;
    while(scanf("%c",&sen)!=EOF){
        if(sen>='a'&&sen<='z'){
            int num=sen-'a';
            counter[num]++;
        }else if(sen>='A'&&sen<='Z'){
            int num=sen-'a';
            counter[num]++;
        }
    }
    for(i=0;i<26;i++;){
        printf("%c : %d",i+'a',counter[i]);
    }
return 0;
}

Compiler output:
main.c: In function 'main':
main.c:14:21: error: expected ')' before ';' token
   14 |     for(i=0;i<26;i++;){
      |        ~            ^
      |                     )