总结

bool 函数 要return 0 *

bool initlist(node*& temp) {
temp = new node;
if(!temp)
if (temp == NULL) return false;
temp->next = NULL;
return true;
}


“\n” 和endl 效果相同 if() { }else //这里else前不能加; 对象 可以是函数参数 返回值 C 语言使用变量对数组进行定义时,但却不能同时对其进行初始化赋值操作,需要在之后进行。

vector std::sort() //sort(word.begin(), word.end());

std::stoi // string 转换成int
std::reverse(str.begin(), str.end());//反转string型字符串
 

 

posted @ 2022-03-02 15:52  Dsad123FFFG6645  阅读(8)  评论(0)    收藏  举报