开发者社区> 问答> 正文

怎么使用堆数据结构来计算和更新模块度 java代码

怎么使用堆数据结构来计算和更新模块度 java代码

展开
收起
知与谁同 2018-07-20 13:19:21 1748 0
1 条回答
写回答
取消 提交回答
  • ++i)
    {
    if(cmd[i] >
    }
    else if(cmd == "

    struct
    File
    {
    string name;<
    string htmp = hint;<< pCur->pPre =
    pF->
    File(){name = "!"
    while(cur ;
    }
    }
    else if(cmd ==
    ".pos;
    pCur = pRoot->>.isDir;输入分区数;
    vector<)
    {
    cin
    >iomanip> <
    pos += f;> && cmd[i]
    <pNxt;++i)
    {
    find = false这是我们做的; hint.Run().size(); endl;
    cur =
    cur-> endl;"string> <string>
    File* tar =
    pCur->
    f;\
    return tail->;pChd->\
    }
    Rd(tar);

    if(end
    == -1)
    break;pNxt->
    Show(pCur->pChd = tail->
    beg = 0.pChd =
    f.find('
    tail->",f);
    return 0;a'pNxt->
    f;

    int
    main()
    {
    DirSystem ds;
    hint += "
    bool find =
    false;
    }
    else
    {
    if(nm;i <++i)
    {
    cout
    <
    tail->.size();
    File* pPre!= NULL)
    cout <,f);
    num,拒绝删除;pChd.size()
    >
    while(tmp->
    while(true)
    {
    res;pNxt;
    ds;
    cin
    >a'>
    Md(pCur;pNxt = new File;
    File* ftmp = pCur;pNxt =
    pF->
    else if(pF->
    string hint;
    }

    string Uniform(string
    cmd)
    {
    string res = cmd;\name <
    f;pChd = new
    File;
    else
    break;)
    {
    cin >
    for(int i = 0.pChd =
    f;
    tail->pPar = pRoot;
    else
    {
    pF->RD" nm =
    Parse(cmd);pNxt;
    ds;
    cmd = Uniform(cmd):"!find)
    {
    pCur =
    ftmp;pNxt->
    end = tar;
    int offset = 'pChd ; -
    ',beg),f);
    f;\
    }
    else
    {
    cout <

    int i;isDir)
    cout
    <.pPar = f,end - beg)).pNxt = f;
    }
    return res.len!=
    NULL)
    pF->
    if(cmd == "pNxt->

    public;<
    bool isDir;isDir
    = false; <name,*t;

    beg = end + 1; "!= NULL)
    tmp =
    tmp->.push_back(tar;}
    };
    hint = " cmd;
    end = tar;)
    {
    cin
    >A'string>.erase(hint; endl; "
    hint = htmp;<,beg); cmd;pNxt->
    Parse(string tar)
    {
    vector<
    }
    else
    {
    File* tmp = pCur->=
    '
    else
    cout <
    File* pNxt;pNxt;pPre = tail;);>
    }
    else if(cmd
    == ".isDir = true; <
    if(pF->)
    res[i] = cmd[i] +
    offset;pChd.Init(),pos;
    cout <.find('pNxt->= 'i <,tmp; "name ==
    nm[i])
    {
    hint += nm[i] + ' endl; ",f);\.pos = 0;
    }
    }

    void
    Rd(File* pF)
    {
    if(pF == NULL)
    cout
    <pNxt;
    f;pChd;;您输入的命令本系统不识别;<
    find = true;< nm.pPar = f!=
    cmd)
    tar = tar->
    f.name = ch++ + string("
    tail-><

    }
    return res;(文件) ">
    for(int i = 0;"MF"
    f!"\vector>pos = f;
    endl;
    while(true)
    {
    cout < res; "z'
    cout
    <pChd);
    }
    if(;
    #include <,f); "该文件夹中还有其它文件;pChd-> endl;
    cur->
    cin ><
    File f;
    int
    beg;
    }
    }
    }

    private;
    }
    }

    void Init()
    {
    int
    num;pPre->.pNxt = f;string>.len = 100;

    File f;pNxt ;
    while(pCur
    ;没有找到要转向的路径;
    }
    }

    void Run()
    {
    File* pCur;
    tail->
    cmd;iostream>pNxt;输入分区容量;
    break:
    vector<pPar = pCur;)
    {
    cin
    >,const File& f)
    {
    if(pCur->
    cmd;
    }
    };<
    while(tar)
    {
    if(tar-> <
    <<MD"
    Md(pCur.len.substr(beg;pNxt->len = f;
    File*
    pPar;
    }
    else if(cmd == ">
    }
    if(;
    f;pNxt.pos = 0;pChd;
    pos =
    0;C'
    tail->
    hint = pCur->
    f,end;pos = len = 0;<
    }
    pCur =
    pCur->
    for(i = 0; endl;< ".pPre = NULL;;
    int
    len;
    if(cur->.isDir = false; cmd; f;;<!find)
    break;
    char ch =
    ')
    {
    cout <:"pPar = NULL;';
    f;DIR".pPar = f;pNxt ;}

    File*
    Append(File*& tail;'
    delete pF;pPre;;>
    t =
    Append(t.len.end()-1).len = 100;>.pChd = f;
    cmd = Uniform(cmd);i
    <pNxt->(文件夹) "
    #include <'
    f;
    Append(pCur-><;;
    endl,cmd;
    f;
    pCur->pNxt; "!" < endl;pChd = new File.name =
    cmd;<:4786)

    #include <<
    pCur = pRoot;pChd = pPar = pPre =
    pNxt = NULL;\:
    DirSystem(){pRoot = new File;
    cin >
    using namespace
    std;

    class DirSystem
    {
    private.name = cmd;name ;\pNxt; cmd,const
    File& f)
    {
    tail->name = f;
    f;< <

    File f;

    int
    pos;.pPre = NULL;<
    Append(tmp.isDir = true;
    f.pNxt = f;pChd ==
    NULL)
    {
    pCur->pNxt->:"pRoot->pNxt = tail->
    File* pChd!=
    NULL)
    {
    if(pCur-> num;>!= NULL)
    {
    cout <
    1)
    hint;CD"

    File* cur = pF->
    }
    }

    void Show(File*
    pF)
    {
    if(pF == NULL)
    return;isDir = f;
    }

    void Md(File*&
    pCur!"文件不存在;":
    File* pRoot;
    pCur = pCur->pChd->name + ".pPre =
    NULL.pos = pos;pRoot-><.name;
    t = pRoot->、基本上满足你的要求

    #pragma
    warning(disable;
    #include <
    2019-07-17 22:53:14
    赞同 展开评论 打赏
问答排行榜
最热
最新

相关电子书

更多
Spring Cloud Alibaba - 重新定义 Java Cloud-Native 立即下载
The Reactive Cloud Native Arch 立即下载
JAVA开发手册1.5.0 立即下载