freelanceprogrammers.org Forum Index » C
problem with transform
Joined: 07 Jan 2005
Posts: 3
problem with transform
Hi Everyone,
This is my first mail to the group. I had a problem with the
following program to convert a string to uppercase using the transform
algorithm.
#include<algorithm>
#include<iostream>
#include<vector>
#include<string>
#include<iterator>
#include<cctype>
using namespace std;
int main(){
string s = "lmnopqrst";
transform(s.begin(),s.end(),s.begin(),toupper); // i am getting
compile error at this line
char ch;
cin>>ch;
return 1;
}
Please help me solve this. Thanks in advance.
Bye
Mahesh S.
Joined: 25 Jul 2003
Posts: 48
problem with transform
Reply embedded...
> -----Original Message-----
> From: mahesh s [mailto:smahesh555@...]
> Sent: Saturday, January 29, 2005 3:36 AM
> To: Programmers-Town@yahoogroups.com
> Subject: (PT) problem with transform
>
>
>
> Hi Everyone,
>
> This is my first mail to the group. I had a problem with the
> following program to convert a string to uppercase using the transform
> algorithm.
>
> #include<algorithm>
> #include<iostream>
> #include<vector>
> #include<string>
> #include<iterator>
> #include<cctype>
> using namespace std;
>
> int main(){
> string s = "lmnopqrst";
> transform(s.begin(),s.end(),s.begin(),toupper); // i am getting
> compile error at this line
I don`t. What compiler/version are you using?
> char ch;
> cin>>ch;
> return 1;
> }
>
> Please help me solve this. Thanks in advance.
>
> Bye
> Mahesh S.
>
Joined: 07 Jan 2005
Posts: 3
problem with transform
On Thu, 3 Feb 2005 09:25:45 -0600, Shyan Lam <sflam@...> wrote:
> Reply embedded...
>
> > -----Original Message-----
> > From: mahesh s [mailto:smahesh555@...]
> > Sent: Saturday, January 29, 2005 3:36 AM
> > To: Programmers-Town@yahoogroups.com
> > Subject: (PT) problem with transform
> >
> >
> >
> > Hi Everyone,
> >
> > This is my first mail to the group. I had a problem with the
> > following program to convert a string to uppercase using the transform
> > algorithm.
> >
> > #include<algorithm>
> > #include<iostream>
> > #include<vector>
> > #include<string>
> > #include<iterator>
> > #include<cctype>
> > using namespace std;
> >
> > int main(){
> > string s = "lmnopqrst";
> > transform(s.begin(),s.end(),s.begin(),toupper); // i am getting
> > compile error at this line
>
> I don`t. What compiler/version are you using?
>
>
> > char ch;
> > cin>>ch;
> > return 1;
> > }
> >
> > Please help me solve this. Thanks in advance.
> >
> > Bye
> > Mahesh S.
> >
>
>
>
>
> To unsubscribe : programmers-town-unsubscribe@yahoogroups.com
>
Hi Shyan,
Sorry for that.
I am using Dev-C++ version 4.9.9.0
And the compilation error was:
no matching function for call to
`transform(__gnu_cxx::__normal_iterator<char*, ..........
The compiler is not displaying the complete error message.
Bye
Mahesh S.
Joined: 25 Jul 2003
Posts: 48
problem with transform
Reply embedded...
> -----Original Message-----
> From: mahesh s [mailto:smahesh555@...]
> Sent: Thursday, February 03, 2005 8:52 PM
> To: Programmers-Town@yahoogroups.com
> Subject: Re: (PT) problem with transform
>
>
>
>
> Hi Shyan,
> Sorry for that.
> I am using Dev-C++ version 4.9.9.0
I don`t use Dev-C++, I though it is only an IDE that can work with several
compiler. You might want to check what`s the underlying compiler that is
use to compile your code - It is probably MinGW.
> And the compilation error was:
> no matching function for call to
> `transform(__gnu_cxx::__normal_iterator<char*, ..........
>
> The compiler is not displaying the complete error message.
Unfortunately, I don`t use MinGW either. But I did find several discussion
about this in its SourceForge forum:
<
http://sourceforge.net/search/?type=mlists&exact=1&q=transform&offset=25&gro
up_id=2435&forum_id=5119 >
(Note: URL might line-break by mail client)
See if any of those are related or helpful.
Shyan
All times are GMT
Page 1 of 1
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Freelace Website Designer - Customer web design and software building.
China Wholesale - Electronics Products
Character Studio - Tutorials and Help
China Wholesale - Electronics Products
Character Studio - Tutorials and Help







