now that i'm in the office and have my code handy, here's the routine i'm using:
def add(num,num2):
sum = str(int(num) + int(num2))
return 'The sum of %s and %s is: %s' % (num,num2,sum)
the output, as printed within a new blip and within my GAE logs, is:
"The sum of 5 and 6\n is: 11"
thoughts?
On Fri, Aug 7, 2009 at 6:39 AM, Jason
Salas<[email protected]> wrote:
> I have this problem, too...I'm working in Python and doing string
> interpolation and the outputted content that gets printed in a new
> blip for some reason has a newline. I can't figure out why.
>
> On 8/6/09, jamz2010 <[email protected]> wrote:
>>
>> Hi all,
>>
>> I am having some issues with reading the last blip from my wavelet in
>> my robot. I have used the line
>>
>> String sLastBlip = e.getBlip().getDocument().getText();
>>
>> to get me the last blip that was added to the wave but it appears to
>> be automatically adding a new line to the end of the wave. I have
>> tried using
>>
>> sLastBlip = sLastBlip.replaceAll("\n", "n").replaceAll("\r", "r");
>>
>> to remove all the new line characters from the string but this doesn't
>> appear to work. I can use
>>
>> sLastBlip = sLastBlip.substring(0, sLastBlip.length()-1);
>>
>> to remove the last character from the string but if the user puts
>> there own new line in it wont work. Does anyone know what character
>> google wave uses for a new line?
>>
>> Thanks
>>
>> James
>>
>> >>
>>
>
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Google App Engine" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/google-appengine?hl=en
-~----------~----~----~----~------~----~------~--~---