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
Anarel [89]
3 years ago
13

An array of String objects, words, has been properly declared and initialized. Each element of words contains a String consistin

g of lowercase letters (a–z). Write a code segment that uses an enhanced for loop to print all elements of words that end with "ing".
As an example, if words contains {"ten", "fading", "post", "card", "thunder", "hinge", "trailing", "batting"}, then the following output should be produced by the code segment.
fading trailing batting
Write the code segment as described above. The code segment must use an enhanced for loop.
Computers and Technology
1 answer:
finlep [7]3 years ago
4 0

Answer:

Explanation:

#include <iostream>

using namespace std;

int main()

{

   string cwords[8]={"ten", "fading", "post", "card", "thunder", "hinge", "trailing", "batting"};

   string temp="";

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

   {

       temp=cwords[i];

       int j=temp.length();

       if (temp[j-3]=='i' && temp[j-2]=='n' && temp[j-1]=='g')

       {

           cout<<temp<<endl;

       }

   }

   return 0;

}

You might be interested in
What need most led to the creation of the Advanced Research Projects Agency Network? DARPA wanted scientists to be able to colla
Bas_tet [7]

(A) DARPA wanted scientists to be able to collaborate and share research easily.

The initial purpose of ARPA was to enable mainly scientific users at the connected institutions to communicate and share resources, also to be able to link computers at Pentagon-funded research institutions over telephone lines, and it became the technical foundation of the Internet.

6 0
3 years ago
Read 2 more answers
A general rule for adding text to a slide is ____.
Rama09 [41]

A general rule for adding text to a slide is to use not more than two fonts in a presentation and vary the font size. Furthermore, to make a slide legible, in addition to the point size, attention must be paid to the word count per slide, the choice of typeface, and the visual balance of  space to text.

4 0
3 years ago
Read 2 more answers
"Different links can transmit data at different rates, with the _______ of a link measured in bits/second"
murzikaleks [220]

Answer: Transmission rate

Explanation:

 Transmission rate is measured in bits per second and it transmitted the data at the different rate across the circuit. The speed in which the data rate is transferred from one device to anther is known as transmission rate.

The transmission rate are always less as compared to signalling rate because the signalling rate contain the total data which basically include the overhead to control the information.

Therefore, transmission rate is the correct option.

 

7 0
3 years ago
How to tell if screen or screen protector is cracked?
beks73 [17]
You will feel the screen protector crack
6 0
4 years ago
Read 2 more answers
A hard disk is a _ storage device
Leokris [45]

electro-mechanical data storage device

5 0
3 years ago
Read 2 more answers
Other questions:
  • High-speed memory that reduces the frequency of access by the cpu to conventional memory is called
    12·1 answer
  • What port in your computer will you use to plug in your camera?
    14·2 answers
  • e do loop differs from the while loop in that a. the while loop will always execute the body of the loop at least once b. the do
    9·1 answer
  • What was the original motivation for developing the internet?
    7·1 answer
  • Is it important for a writer to include voice and point of view in writing because...<br> Plz help
    10·1 answer
  • Please help! I tried this by myself. But I am not sure if this is right.
    8·2 answers
  • You wrote a program to compare the portion of drivers who were on the phone. Which statements are true? Select 4 options.
    12·1 answer
  • A _______ is a group of elements that you want to style in a particular way.
    8·2 answers
  • Which statements describe the advantages of using XML
    5·1 answer
  • HELP ME PLEASE 41 PTS
    12·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!