Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# HacktoberFest2021-2
A beginner-friendly project to help you in open-source contributions. Made specifically for contributions in HACKTOBERFEST 2021. Please leave a star ⭐ to support...…
27 changes: 27 additions & 0 deletions find_word.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
// WAP enter a sentence form keyboard and also find all the words in that
// sentence with starting character as vowel
import java.util.Scanner;
class Assginment2
{
public static void main(String[] arg)
{
String store="\n";
char vowel=a;
Scanner sc=new Scanner(System.in);
System.out.print("Enter a string : ");
String take=sc.nextLine();
String[] arr=take.split(" ");
for (String s : arr)
{
System.out.println(s);
int le=s.length();
String[] arr2=new String[le];
arr2=
if (arr2[0]==vowel)
{
store+=s;
}
}
System.out.println("These are the words which start with vowel : "+store);
}
}