case convertion from lower ro upper and vice versa

+1 ragmar thomas · July 19, 2014
how to convert a random string from the user to upper or lower case just like a dictionary application whether the user typed it in upper case or lower case it search if possible with out any header files.

Post a Reply


- page 2
Oldest  Newest  Rating
+1 Dima Sama · August 1, 2014
You have a point and i support you for that. But let me just clarify things.

You're right; He probably isn't getting paid for this program... Not for this program, no.

This is one of the programs that helps him get his diploma.

THEN he'll get paid... but when he can't find an example of what he wants to do at work, he'll think back to those days when people did work for him here, and he'll ask around here.

You just assume he is a college student. I'm not saying he is not, but its best not to assume things. He didn't even mention what he is. Anyway, i doubt he never tried to think on his own. So let's not assume. He'll think back to those days and ask around here? Really? You'd think someone will dare answer him if he ever ask how to make a database on a certain company? I don't think so.

isupper/lower/etc and toupper/lower/etc are documented to take an int argument, which is then treated as though it's an unsigned char value. Giving them negative char values is undefined behaviour, and actually causes assertion errors for some implementations, eg.

If someone tried to explain like that i don't think he really understood c++ that well. It's no different from reading a book. Try answering like that and you would be bombarded with another questions no different from the initial one. For god's sake if my tutor put a site like that he failed miserably.

In addition, it's best not to encourage or rely upon ASCII tricks (such as adding or subtracting 32) because they're not future-proof (or even past-proof). Neither C nor C++ require that ASCII be used as the character set; EBCDIC is equally valid. Though rare as it is in this day and age, your advice will presumably be there forever; You wouldn't want to be seen giving invalid advice some day, would you?

There's a reason i explained ascii tricks on the bottom right? I never mention he/she should use that. I'm just merely giving him/her some options. I also include it so that he/she can understand the logic behind that conversion.

I don't care what others see or think of me. I'm not asking for fame or money. I'm just helping. You can ignore my advice if it was deem useless or invalid but it doesn't change the fact that i'm just helping right?

The best thing to "explain to him" is that which he has yet to understand, and you can't do that without first determining what he has tried.

In this case, he posted no code. Ask him to post code! Ask him what he's tried! Ask him what he didn't understand! If you don't do these things, if you just spoonfeed him... You're failing him.

Yes i agree to you with this one. But if you really read his question you will know what he didn't understand. And if you really reading this thread you should have known my first response to this thread and our initial conversation.
+2 Brandon Elliott · August 1, 2014
Some people really like to argue :silly:
0 ragmar thomas · August 2, 2014
for the record this was an assignment nearly a month a go and trust me it was the best when i presented it because it wasn't copied and pasted after what i have earned what i deserve i wasn't satisfied with what i have accomplished i want it to be better so i need to find someone better particularly here and not yet i ain't even planning to be payed at most nearly (and back to the problem do you guy know any ways to work with strings and fstream , thanks in advance and i hate copy and paste trust me 'm old enough to hate it and i don't what to do my work for me just little help tips that's it)
0 ragmar thomas · August 2, 2014
lol you have all lost me i have already a diploma or what ever you call it of course in other filed and lately 'm kind interested in the tech world not for the sake of carrier but for passion(and hopefully one day it will be my carrier) it's been about 10 month since i enrolled to my new course and its my first programming language to start again to my topic it gives unexpected results while using char and string with cotes when comparing them with each other.

And btw there were offensive comments am old enough not to feel about the BS if i were a teenage or my first college tour it would have been a disaster and please don't bash smash someone work just like that(this no different than bullying) who ever you are probably you were the worst or had been through try to be positive there might be kids out here or there please am begging you not for me off course.peace   
0 ragmar thomas · August 2, 2014
waow you have issues, dude trust me i have already A+ in my previous course i just posted this for my own sake i want to be a kick-ass for real in this language and please enough with the BS thing if you know how to help me do it then other wise go some where else and play candy crash kid.
  • 1
  • 2



Used in many types of software including music players, video games, and many large scale applications.

Bucky Roberts Administrator