+ 1

Why it is showing no output please help me😢

https://code.sololearn.com/cbg1AS75gK92/?ref=app

5th Sep 2020, 5:02 AM
iiiii
4 odpowiedzi
+ 3
//Created by MUHAMMED.Hassan /* just input any sentence it will show you the frequency of words ☺️ still in progress showing no output you solve error inbox me */ import java.io.*; import java.util.Scanner; class Hassan { public static void main(String[] args) { String s; int i,j,l,f; Scanner scan = new Scanner(System.in); System.out.println("Enter a string in upper case"); s=scan.nextLine(); l=s.length(); for(i=65;i<=90;i++) { f=0; for(j=0;j<l;j++) { if(s.charAt(j)==i) { f++; } } if(f>0) { System.out.println((char)i+"\t"+f); } } } } Try this I make some changes.
5th Sep 2020, 5:48 AM
Muhammadamin
Muhammadamin - avatar
+ 3
what is i?
5th Sep 2020, 5:24 AM
Oma Falk
Oma Falk - avatar
+ 2
You are welcome
5th Sep 2020, 6:09 AM
Muhammadamin
Muhammadamin - avatar
+ 1
Oh!its work thanks😃
5th Sep 2020, 6:07 AM
iiiii