0

c++ program to print the words start with "h" in a given multi word text using getline() and write()

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

15th Feb 2020, 8:48 AM
Fatima
12 odpowiedzi
+ 3
Good try, but No, you shouldn't only check the first letter of the whole sentence. You need to split the sentence into words. Loop through the words, and check their first letter one by one. Do not output those word without h as first letter.
15th Feb 2020, 9:06 AM
Gordon
Gordon - avatar
+ 2
Please reply with one message, this isn't a chat board : ) Anyways, did you understand the hints given by my friend Gordon? He had given you clear notes on what to do. What part is hard on this task, can you tell?
15th Feb 2020, 10:19 AM
Ipang
+ 2
See this example about splitting string 👍 https://www.geeksforgeeks.org/tokenizing-a-string-cpp/
15th Feb 2020, 11:25 AM
Ipang
+ 1
Please tag C++ to improve context clarity 👍
15th Feb 2020, 9:58 AM
Ipang
0
Thank you dear
15th Feb 2020, 10:14 AM
Fatima
0
Could you say more about that
15th Feb 2020, 10:14 AM
Fatima
0
By using the loops how to split sentence into word
15th Feb 2020, 10:27 AM
Fatima
0
Can anyone reduce the size of the program By different method or same method The above program is accurate but size is more
15th Feb 2020, 11:37 AM
Fatima
0
Salam fatima See this but i used string not array of char. https://code.sololearn.com/cBSc5f5G74NC/?ref=app
15th Feb 2020, 9:29 PM
Rafik Abdelhak Nadir
Rafik Abdelhak Nadir - avatar
0
Thank you rafik Program is accurate and excellent But using getline() and write() is necessary
16th Feb 2020, 6:31 AM
Fatima
0
Fatima I don't use write() many times, I don't know if I can help you under such restriction. But if I found a way I will tell you here ...
16th Feb 2020, 8:05 AM
Ipang