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
valina [46]
3 years ago
12

Write a c++ program that accepts a string from the user and then replaces all occurrences of the letter e with the letter x

Computers and Technology
1 answer:
mixer [17]3 years ago
6 0

Answer:

#include <iostream>

using namespace std;

int main()

{

   string str;

   cout<<"Enter the string: ";

   cin>>str;

   for(int i=0;str[i]!='\0';i++){

       if(str[i]=='e'){

           str[i]='x';

       }

   }

   cout<<"the string is: "<<str<<endl;

  return 0;

}

Explanation:

First, include the library iostream for using the input/output instructions.

Create the main function and declare the variables.

Then, use the cout instruction and print the message on the screen.

cin store the string enter by the user into a variable.

After that, take a for loop and if-else statement for checking the condition if the string contains the 'e', then change that alphabet to 'x'.

This process continues until the string not empty.

Finally, print the updated string.

You might be interested in
Which of the following best describes professional behavior in the IT field?
Liono4ka [1.6K]
Option A. is the correct answer the other three are not professional behaviour if you would like an explanation as to why they are not just comment
7 0
2 years ago
Read 2 more answers
A series circuit and identify how voltage is split up by each load in the circuit?
Vlada [557]

The same current flows through each part of a series circuit. The total resistance of a series circuit is equal to the sum of individual resistances. ... The voltage drop across a resistor in a series circuit is directly proportional to the size of the resistor. If the circuit is broken at any point, no current will flow.

4 0
3 years ago
When building systems, the only two entities that constitute software engineering are people and process.
VLD [36.1K]

Answer: False

Explanation: Software engineering is the designing, analyzing, creating the software application as per the requirement of the user. The programming languages is the base for the designing of the application the software engineering field.

At the time of building system ,there is the requirement of many resources for the development.There is the requirement of the software skills, programming knowledge, resources and tools for the working and designing.Thus, there are different resources, people,skills processes, problem solving skill etc required for the building of the system.

7 0
3 years ago
After the data are appropriately processed, transformed, and stored, what is a good starting point for data mining?
Oksana_A [137]

Data visualization

Data visualization is a good starting point for data mining. There are several approaches to data mining that supports smart decisions. Data visualization places data in a visual context. It extracts the data in a clear and understandable way without any form of reading or writing. Results are displayed in the form of pie charts, graphs, and any other statistical representation. Such multidimensional views of data aid in developing a preliminary understanding of the trends that are hidden in the data set.

7 0
3 years ago
12.
natali 33 [55]

Answer:

The answer is "Its fundamental economic structure of IP, which is based on the concept of incentives".

Explanation:

In the given question the correct choice is missing so, its solution can be defined as follows:

It is a copyrighted category that includes subjective human mind works. which exists in different forms, and also some countries recognize much more than others. Copyright laws, patents, trade secrets, and trademarks are the most famous types.  

  • This is a law that promotes the creation of a broad range of intellectual goods.
  • To do just that, the law gives the information and creative goods made, generally for a limited time, rights to individuals and companies.
7 0
3 years ago
Other questions:
  • Lossless and lossy are the two (2) universally known categories of compression algorithms. Compare the two (2) categories of alg
    8·2 answers
  • Use the Web as a resource to study the PDF format. a. Describe how PDF provides output that is consistent across different types
    8·1 answer
  • Playstation network live updates pes 2018 does it cost extra
    13·1 answer
  • Apple users tend to like the company and love its products. Apple has successfully nurtured this __________ component of its cus
    15·1 answer
  • If the variable letter has been defined as a char variable, which of the following are not valid assignment statements to assign
    8·1 answer
  • When you use the 3 bits 100 what color will it produce?<br><br> Computer Science
    11·1 answer
  • How can a search be narrowed to only search a particular website????
    15·1 answer
  • New product ideas must fit into a company's mission statement and?
    12·1 answer
  • write ms-dos command to list all the files and folders of EIGHT sub directory of C: drive in ascending order according to file n
    5·1 answer
  • Complete the code to finish this program to analyze the inventory for a store that sells purses and backpacks. Each record is co
    13·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!