一个strlen的问题

#include <iostream>
#include <cstring>
using namespace std;
int main()
{
    if(-1<=strlen("Hello world"))
    {
        cout<<"-1<=strlen(\"Hello world\")"<<endl;
    }
    int nLen=strlen("Hello world");
    if(-1<=nLen)
    {
        cout<<"-1<="<<nLen<<endl;
    }
    return 0;
}

结果:

-1<=11

posted @ 2012-04-11 15:59  likebeta  阅读(208)  评论(0编辑  收藏  举报