从文本文件中排序

时间:2013-02-21 00:57:40

标签: c++ sorting

我有一个我正在调用的文本文件,我应该做的是创建一个名为add_aa(str)的方法,它添加str并按字母顺序对其进行排序。我正在考虑编写一个for语句,但是,不确定如何真正设置它。

inline void LList:: add_aa(const string str)
{
    cout << "_head = " << std::hex << _head << std::dec << '\n';
    cout << "p = " << std::hex << p << std::dec << '\n';
    cout << "_str = " << std::hex << _str << std::dec << '\n';
    cout << "_prev = " << std::hex << _next << std::dec << '\n';
    cout << "_tail = " << std::hex <<_tail << std::dec << '\n\;
}

附件也是它看起来像的输出 enter image description here

0 个答案:

没有答案