toupper() function in turbo (borland) c++ ?!?!
Hello...
I have this sort of a problem... In visual c++ I used the toupper(int) function, so I had this code:
int chr;
chr = getch();
chr = toupper(chr);
The problem is that Turbo C++ can''t find the toupper() function, that should have ben defined in conio. Is there another way of doing this code in turbo c++ ???
you could always write your own...
--- Edit ---
Just wanted to say, that I used to use toupper in Borlan's Turbo C/C++, and I beleive it's in the strings.h include file, but don't hold me to that.
[edited by - Ready4Dis on April 2, 2003 10:09:03 AM]
char toupper(char t){ if (t>='a' && t<='z') t-=('a'-'A'); //Subtract the difference between lower case and upper case a return t;}
--- Edit ---
Just wanted to say, that I used to use toupper in Borlan's Turbo C/C++, and I beleive it's in the strings.h include file, but don't hold me to that.
[edited by - Ready4Dis on April 2, 2003 10:09:03 AM]
It should be (i.e. standard):
[ Google || Start Here || ACCU || MSDN || STL || GameCoding || BarrysWorld || E-Mail Me ]
#include <cctype>
int chr = getch();
chr = toupper(chr);
[ Google || Start Here || ACCU || MSDN || STL || GameCoding || BarrysWorld || E-Mail Me ]
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement