Day 10 of my Java Daily Tasks focuses on String Problem Solving.
In Day 09, I learned the basic operations of strings. In Day 10, I am applying strings to solve more logical and problem-solving-based programs.
This day includes counting vowels and consonants, counting digits and words, finding characters, removing vowels, checking anagrams, finding duplicate characters, counting character frequency, and reversing each word.
The main objectives of Day 10 are:
charAt()length()toLowerCase()replace()split()Day-10-String-Problem-Solving/
│
├── Questions/
│ └── Questions.txt
│
├── Screenshots/
│ ├── Output_1.png
│ ├── Output_2.png
│ ├── Output_3.png
│ ├── Output_4.png
│ ├── Output_5.png
│ ├── Output_6.png
│ ├── Output_7.png
│ ├── Output_8.png
│ ├── Output_9.png
│ └── Output_10.png
│
├── Solutions/
│ ├── Q01_Count_Vowels_And_Consonants.java
│ ├── Q02_Count_Digits.java
│ ├── Q03_Count_Words.java
│ ├── Q04_Find_First_Character.java
│ ├── Q05_Find_Last_Character.java
│ ├── Q06_Remove_Vowels.java
│ ├── Q07_Check_Anagram.java
│ ├── Q08_Find_Duplicate_Characters.java
│ ├── Q09_Find_Frequency_Of_Character.java
│ └── Q10_Reverse_Each_Word.java
│
└── README.md
Count the number of vowels and consonants present in a given string.
Count the number of digits present in a given string.
Count the number of words present in a given sentence.
Find and print the first character of a given string.
Find and print the last character of a given string.
Remove all vowels from a given string and display the remaining characters.
Check whether two given strings are anagrams of each other.
Find and print the duplicate characters present in a given string.
Find how many times a given character occurs in a string.
Reverse each word in a sentence without changing the order of the words.
| No. | Problem | Solution |
|---|---|---|
| Q01 | Count Vowels and Consonants | Q01_Count_Vowels_And_Consonants.java |
| Q02 | Count Digits | Q02_Count_Digits.java |
| Q03 | Count Words | Q03_Count_Words.java |
| Q04 | Find First Character | Q04_Find_First_Character.java |
| Q05 | Find Last Character | Q05_Find_Last_Character.java |
| Q06 | Remove Vowels | Q06_Remove_Vowels.java |
| Q07 | Check Anagram | Q07_Check_Anagram.java |
| Q08 | Find Duplicate Characters | Q08_Find_Duplicate_Characters.java |
| Q09 | Find Character Frequency | Q09_Find_Frequency_Of_Character.java |
| Q10 | Reverse Each Word | Q10_Reverse_Each_Word.java |










cd Day-10-String-Problem-Solving
cd Solutions
Example:
javac Q01_Count_Vowels_And_Consonants.java
java Q01_Count_Vowels_And_Consonants
The same process can be followed for the remaining programs.
Through Day 10, I practiced:
The goal of Day 10 is to build a strong foundation in string-based problem solving before moving toward more advanced Java topics such as:
| Day | Topic | Status |
|---|---|---|
| Day 10 | String Problem Solving | ✅ Completed |
M. Praveen Kumar
⭐ This is part of my Java Daily Tasks journey to improve my Java programming and problem-solving skills.