1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
jolli1 [7]
3 years ago
7

Write a program that reads a series of strings andprints only those strings beginning with the letter "b."

Computers and Technology
1 answer:
coldgirl [10]3 years ago
6 0

Answer:

#include <iostream>

using namespace std;

int main()

{

char str[100][20];

int n;

cout<<"Strings you want to enter"<<endl;

cin>>n;

cout<<"enter n strings"<<endl;

for(int i=0;i<n;i++)

cin>>str[i];

for(int i=0;i<n;i++)

{

if((int)str[i][0]==98) //ascii value b is 98

cout<<str[i]<<endl;

}

return 0;

}

Explanation:

The above written code is for printing the strings which starts with the letter b.

To check if the string starts with a letter b we are checking the ascii value 98 which corresponds to b and then printing those strings.

You might be interested in
Java question
skad [1K]

Answer:

To be honest why would you want to enter one character. Anyways the answer is option 4

6 0
3 years ago
Steve left his computer switched on in his room and went out to have breakfast. When he returned, he saw that the monitor had be
yanalaym [24]

Answer:

B

Explanation:

5 0
3 years ago
What forms the foundation of cloud computing?
makkiz [27]
Virtualization. To enable easy deployment and scalability, it should be easy to spin up new machines on request. Virtualization offers the possibility to clone operating systems and deploy solutions independent of the actual hardware.
8 0
3 years ago
What will you see on the next line? &gt;&gt;&gt; int(6.5)
tankabanditka [31]

Answer:

6

Explanation:

The int functions founds down to the nearest whole number, which in this case would be 6.

8 0
3 years ago
Read 2 more answers
In how many sections is the Add Animation pane divided? What is the utility of each section?​
NikAS [45]
It’s 45 sections they divided
3 0
3 years ago
Read 2 more answers
Other questions:
  • A Hierarchy Custom Setting stores a specific URL for each profile in Salesforce. Which statement can a developer use to retrieve
    5·1 answer
  • What is the purpose of an arraignment?
    9·2 answers
  • What technique can improve web search results? Add articles, prepositions, and pronouns Be general rather than specific Focus on
    10·1 answer
  • What is another term for technology?
    12·1 answer
  • What is hydraulic fracturing?
    7·1 answer
  • What are the five types of alignment in Word?
    12·2 answers
  • Which of the following prefixes would be best to use when measuring your own mass?
    15·1 answer
  • I need help ASAP please and thank you!
    6·1 answer
  • A nested folder can best be described as what?
    12·1 answer
  • Alayna is researching information online to write her essay about the Berlin Wall.
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!