Linked Questions
75 questions linked to/from How to convert an instance of std::string to lower case
1
vote
1
answer
334
views
Partial Name Search
Can someone give me an example of how to partial name search or make the search not case sensitive. I typed these functions to search by last name but I was wondering how to partial name search/non-...
0
votes
1
answer
239
views
Case-insensitive comparison
Sorry to bother with this. This is a basic function, but I am still new the whole realm of C++. I am trying to allow any form of the word "hello". I want the program to allow input any form of hello, ...
-1
votes
1
answer
283
views
C++ Player Creation Menu
I am trying to make a text based C++ game.
I have a player class set up and I am now working on a method inside that class called displayMenu(), which will ask the user a variety of questions based ...
0
votes
1
answer
152
views
What is wrong with my code? I get an error saying I have no declared 'name' but I do not know how to do this (beginner)?
For this program I am trying to make first ask for the users name, print this as a lowercase, and then make a menu, and then for option 1 the program asks the user to guess a random number between 1-...
-1
votes
3
answers
76
views
Issues with IF statement
The application asks the user to enter the students major - either math or CIS and I wanted to make it so if the user were to enter something other than those two it would give an error message and ...
0
votes
2
answers
157
views
Compare string from the user [duplicate]
I am trying to delete a node from the linked list. Node has a name that user enters. But I couldn't figure out how can I ignore the uppercase/lowercase in while loop. Here is my code.
void del(string ...
1
vote
2
answers
123
views
Trouble bubble sorting alphabetically in struct array
When trying to bubble sort an inventory stored in a struct array, I am getting two different errors when I compile the code below:
void SORT_INVENTORY(Books* list, int max, int position)
{
...
0
votes
2
answers
143
views
any way to read in and make lower case in same step?
I'm reading in user input via
string word;
while(cin >> myWord)
//put myWord in array
but for the sake of sorting I want "This" and "this" to be the same. For my sort algorithm I'm using ...
2
votes
2
answers
69
views
My function's return is printing to the console and it will only work every other time I call it C++
I was just playing around with c++ and decided to make a text based RPG. I created a method to get info from the user and change it to lower case. This is the function:
std::string getInfo_ToLower(...
0
votes
1
answer
93
views
Removing capitals and lengthening contractions in a string
I'm trying to replace any capitals as well as lengthening any contractions used in a string. I'm trying to find the fastest and most efficient approach.
Here is my attempt, which is not working:
...
0
votes
0
answers
105
views
Sort array and change upper to lower in C++
I am writing a code in which I have to sort an array by ASCII, change upper letters to lower letters and also words which begin with "ch" have to be placed after words which begin with "h". This is my ...
1
vote
2
answers
85
views
Case insensitive sorting for own-made class objects
I have made an class called Person made up by other classes as Name and Adress. Objects of the Person class is stored in a vector called personList. Everything works fine but my method for sorting!
...
0
votes
1
answer
64
views
How to transfer text from one dimension of array to another in lowercase in c++?
So basically I have a string array called QandA[2][55].
QandA[0][0-55] contains questions (0-55 is the range)
QandA[1][0-55] contains the answer to these questions
Now I have to make a loop that ...
0
votes
0
answers
32
views
This code is not comparing the input. What is the problem in it? [duplicate]
/ This is the header file If i try to get input , it is not comparing it./
bool read_boolean(string prompt)
{
string result;
result = read_string(prompt);
string to_lowercase(const string &text);
...