I have a C++ question. I'm reading words from a text file and storing each words...

50.1K

Verified Solution

Question

Programming

I have a C++ question. I'm reading words from a text file andstoring each words in an array. Currently I'm doing it like thecode below and its working fine but I need all the words to bestored in the array as lower case letters. How can I do this? Thankyou.

if(file.is_open())

    {

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

        {

            file>> array[i];

        }

    }

Answer & Explanation Solved by verified expert
3.8 Ratings (494 Votes)
Here iam providing the code for the given program withexplanation with commentsCode in textForamtyou can copy it and    See Answer
Get Answers to Unlimited Questions

Join us to gain access to millions of questions and expert answers. Enjoy exclusive benefits tailored just for you!

Membership Benefits:
  • Unlimited Question Access with detailed Answers
  • Zin AI - 3 Million Words
  • 10 Dall-E 3 Images
  • 20 Plot Generations
  • Conversation with Dialogue Memory
  • No Ads, Ever!
  • Access to Our Best AI Platform: Flex AI - Your personal assistant for all your inquiries!
Become a Member

Other questions asked by students