精品偷拍一区二区三区,亚洲精品永久 码,亚洲综合日韩精品欧美国产,亚洲国产日韩a在线亚洲

  • <center id="usuqs"></center>
  • 
    
  • what is the mean of function ?

    what is the mean of function ?
    I want to know something about function in c++,and how to use it in programming !
    especially in function overload!
    help!
    其他人氣:174 ℃時(shí)間:2020-02-04 07:21:25
    優(yōu)質(zhì)解答
    A class may have several constructors, for example:
    class myClass {
    //constructor 1
    myClass(int nx,int ny, int size){ c = nx * ny;};
    //constructor 2
    myClass(int nx,int ny, int nz, int size){ c = nx * ny * nz;};
    .
    }
    When you generate instances of myClass, you may use:
    myClass d2,d3;
    d2.myClass(nx,ny,c);
    d3.myClass(nx,ny,nz,c);
    or use
    d2.myClass(nx,ny,c);
    .
    b = a / c;
    d2.myClass(nx,ny,nz,c);
    .
    b = a / c;
    the later 2 d2.myClass() are "function overload",
    one with 3 parameters and another with 4 parameters
    我來(lái)回答
    類似推薦
    請(qǐng)使用1024x768 IE6.0或更高版本瀏覽器瀏覽本站點(diǎn),以保證最佳閱讀效果。本頁(yè)提供作業(yè)小助手,一起搜作業(yè)以及作業(yè)好幫手最新版!
    版權(quán)所有 CopyRight © 2012-2024 作業(yè)小助手 All Rights Reserved. 手機(jī)版